So I’m trying to use dijit tooltip.
http://docs.dojocampus.org/dijit/Tooltip
However, they only have the attribute of “connectIds” this seems rather limiting and I’m surprised that it was programmed this way. I don’t know how many hyperlinks my pages will have, so wouldn’t it be better to have an option like “connectByHTMLtag” so that I can map all “a” tags to a specific tooltip? Or even a “connectClasses” would make a bit more sense.
This means I have to manually enter id=”tooltip1″ id=”tooltip2″ etc.
Anyone find a way around this??
You could connect them when the page loads using dojo.query.
Give all of your hyperlinks a class that you can use to select them later:
Then in your JavaScript you can use something like this:
This code is untested, but that’s basically how you could do it. dojo.query is very handy for this sort of thing!