You will recieve your password to this address. Address is not made public.

Your preferred username that is used when logging in.

Problem with initial position of tooltip inside exposed form, second time triggering OK Created Mar 14, 2010

This thread is solved

Views: 851     Replies: 1     Last reply Mar 15, 2010  
You must login first before you can use this feature

dendy33

Posts: 2

Registered:
Mar 14, 2010

Problem with initial position of tooltip inside exposed form, second time triggering OK

Posted: Mar 14, 2010

I've created form with "expose" behavior,
for element <input ... > I would like show tooltip.

The problem is follow:

After refreshing my page:
http://en.tmf.rtu.lv/test/expo.php

The tooltip is not on its place, but after second time clicking on <input .... > the tooltip is showing in the designed place.

$(document).ready(function(){ :

       $.tools.tooltip.conf.relative= "true";

       $("form.expose").css(
            {
	        'background-color': '#fff',
                'border': '1px solid #fff'
            }
        );

 
        $("#frm :input").tooltip({
                events: { 
                    def: 'focus, focusout',
                    input: 'click , blur', 
                    tooltip: "mouseover",
                    date: 'click, blur' 
                },
                effect: 'fade', 
                relative: "true",
                offset: [ -20, 0],                
                position: "top center",
                opacity: 0.7,
                tip: '.tooltip'
        });     

        // expose the form when it's clicked or cursor is focused
	$("form.expose").bind("click keydown", function() {
               $(this).expose({
                        color: '#150000',
                        opacity: '0.92',
                        // when exposing is done, change form's background color
                        onLoad: function() {
                            this.getExposed().css(
                                 {
                                     'background-color': '#fff',
                                     'border': '1px outset #140000'
                                 }
                            );
                        },

                        // when "unexposed", return to original background color
                        onClose: function() {
                            $("div.tooltip").hide(),
                            this.getExposed().css(
                                 {
                                     'background-color': '#fff',
                                     'border': '1px solid #fff'
                                 }
                            );			
                        },
                api: true
            }).load();
	});


HTML - form:

<form class="expose" autocomplete="off" id="frm" name="frm" action="#" method="post">

<br><br><br><br><br><br><br><br>

<div id="inputs">

<div class="tooltip">eeeeeeee</div>
    <input id="username" name="username" class="request" value="click here" type="text">

<br><br><br><br><br><br><br><br>

</form>

dendy33

Posts: 2

Registered:
Mar 14, 2010

» Problem with initial position of tooltip inside exposed form, second time triggering OK

Posted: Mar 15, 2010

Reply to: Problem with initial position of tooltip inside exposed form, second time triggering OK, from dendy33
Solution:


<form class="expose" style="position: relative;" ......