views:

184

answers:

2

Hi, I am trying to create a little popup div which contains a textbox and two buttons (insert, cancel). this div would appear when you click on a text to edit it. (like tooltip but contains button and text box)

how can i make it by jquery?

thank you alot I am newbie on jquery.

+1  A: 

i recommended on this tool tip

http://flowplayer.org/tools/demos/tooltip/any-html.html

Haim Evgi
+1  A: 
$('#divID').click(function()
{
    $('body').append("<div id='tooltip'><input type='text' /><input type='button' value='Insert' />");
    $('#tooltip').css({'position': 'absolute', 'top': $('#divID').position().top + 'px', 
'left': $('#divID').position().left + 'px'});
});
Devi