qtip2
Posted: Thu Jun 26, 2014 2:31 am
Has anyone here used qtip2 in any of their projects? I'm trying to use it on my image map but it does not seem to work for some reason.
I took the code from here:
http://qtip2.com/plugins#imagemap
And tried to recreate it in my project, but for some reason it doesnt seem to work. My code is:
I know it enters the info function because the alert is called each time I go onto one of the image areas, but a qtip doesnt seem to come up
I took the code from here:
http://qtip2.com/plugins#imagemap
And tried to recreate it in my project, but for some reason it doesnt seem to work. My code is:
Code: Select all
$(document).ready(function(){
function info(txt, title) {
alert("Hello");
$('area').qtip({
content: {
text: 'Support for area maps with no extra configuration! Awesome.'
},
position: {
my: 'top left',
at: 'bottom right'
}
});
}
function writeText(txt)
{
$('#desc').text(txt);
}
$('#HD').mouseover(function(){
var text = "This is a hard drive";
var title = "Hard Drive";
writeText(text);
info(text, title);
});
$("#CPU").mouseover(function(){
var text = "This is a CPU";
var title = "CPU";
writeText(text);
info(text, title);
});
});