1

I am following the documentation as closely as I can, but I can't get the tooltips working. What am I doing wrong?

I've tried a lot of things. Here is some of what I've tried in a sample file.

http://anunexpectacle.com/micros/

I'm pretty desperate now. Please sort me out.

Florent
  • 12,310
  • 10
  • 49
  • 58
KindOfGuy
  • 3,081
  • 5
  • 31
  • 47

1 Answers1

2

It looks like your selector is wrong. When I used this, the tooltips appeared:

$("[rel=tooltip]").tooltip();

Note that $("tooltip") looks for HTML tags like <tooltip>something</tooltip>, but in this case (I guess) you mean to target the links, which have the attribute rel=tooltip.

McGarnagle
  • 101,349
  • 31
  • 229
  • 260
  • I've tried your suggestion in this new file to no avail: http://anunexpectacle.com/micros/index2.html The selector I've used is copied direct from the docs. Any other thoughts? – KindOfGuy Oct 06 '12 at 17:21
  • @KindOfGuy bizarre ... I copied your files locally, and the tooltips work for me in Chrome. Your page is showing this `Unexpected token ILLEGAL` error message that I don't understand, which I suppose may be the cause. http://stackoverflow.com/questions/12719859/syntaxerror-unexpected-token-illegal – McGarnagle Oct 06 '12 at 17:34
  • 1
    @KindOfGuy there's something going on with your file's encoding. I'd try copy/pasting the whole thing to a new file, and making sure to save it with UTF-8 encoding. – McGarnagle Oct 06 '12 at 17:36
  • I got rid of that: http://anunexpectacle.com/micros/index3.html Still doesn't work for me, nor locally, nor online. Thanks for trying. Any more thoughts? – KindOfGuy Oct 06 '12 at 18:41
  • @KindOfGuy the error is fixed, but now the selector is back to `$("tooltip")` -- try changing back to my suggestion above. – McGarnagle Oct 06 '12 at 18:45
  • Yes, I just saw that. Thanks for persisting. I have no idea where that encoding error came from. This has been one of those grotesque bugs where Satan was overseeing my 'progress'. It took a miracle to get me out of there. You were that miracle. Thank you again – KindOfGuy Oct 06 '12 at 18:51
  • Ha, glad I could help. There will always be those random pull-your-hair-out moments in programming ... – McGarnagle Oct 06 '12 at 18:54