Well then you need to load it on click, e.g.:
$( img[title] ).live( click , function(event) {
$(this).qtip({
overwrite: false,
content: {
text: $(this).attr( title ) ,
},
position: {
my: top center ,
at: bottom center ,
adjust : {
screen : true
}
},
show: {
event: event.type,
ready: true,
solo: true
},
hide: unfocus ,
style: {
classes: ui-tooltip-light
}
});
});
Check out my fiddle: EXAMPLE
Use
adjust : {
screen : true
}
to keep the tooltip on screen.
Here you go. CLICK
$( img[title] ).live( click , function(event) {
var content = $( #settings ).clone();
$( input , content).val( $(this).width() );
$(this).qtip({
overwrite: false,
content: {
text: content,
title: {
text: ,
button: true
}
},
position: {
my: top center , // Position my top left...
at: bottom center , // at the bottom right of...
viewport: $(window)
},
show: {
event: event.type,
ready: true,
solo: true
},
hide: unfocus ,
style: {
classes: ui-tooltip-ajax ui-tooltip-light
}
});
});