This is the code I use to show the qtips:
$(document).on('mouseover', '.sktooltip', function(event) {
// Bind the qTip within the event handler
$(this).qtip({
overwrite: false, // Make sure the tooltip won't be overridden once created
content: 'ToolTip!',
target: 'mouse',
show: {
event: event.type, // Use the same show event as the one that triggered the event handler
ready: true // Show the tooltip as soon as it's bound, vital so it shows up the first time you hover!
}
}, event); // Pass through our original event to qTip
})
// Store our title attribute in 'oldtitle' attribute instead
.each(function(i) {
$.attr(this, 'oldtitle', $.attr(this, 'title'));
this.removeAttribute('title');
});
It's basically the same as the one in the docs.
Now, the relevant HTML before I hover over it:
<div class="service-block msr">
<a target="_blank" href="http://google.de">
<div class="service-image msrc">
<img rel="254" data-original="123.png" class="sktooltip" src="123.png" style="display: inline;">
</div></a>
<h4><a target="_blank" href="http://google.de">Google</a></h4>
<p>Search Engine</p>
</div>
And after:
<div class="service-block msr">
<a target="_blank" href="http://google.de">
<div class="service-image msrc">
<img rel="254" data-original="123.png" class="sktooltip" src="123.png" style="display: inline;" data-hasqtip="0" aria-describedby="qtip-0">
</div></a>
<h4><a target="_blank" href="http://google.de">Google</a></h4>
<p>Search engine</p>
</div>
As you can see, qtip inserts its attributes in the element but I can't see the the tooltip. What am I missing?
Edit: It does work here but not on my website: http://jsfiddle.net/Dayjay/738nX/
It works now! I used jquery.isotope which implements an older version of the imagesLoaded plugin, which caused problems with qTip2 . To solve this, simply include the latest imagesLoaded script after the isotope script.