• Post Reply Bookmark Topic Watch Topic
  • New Topic

Creating ToolTips in JSTL code?  RSS feed

 
Mike London
Ranch Hand
Posts: 1340
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'd like to use the browser's ability to display tooltips using the built-in 'title=' syntax:

<div id = "someId" title="Tool Tip Text" ...

tags here that would show the tool tip text

</div>

The problem is that this type of tool tip display doesn't work (or at least I can't get it to work) with a JSTL variable using "${someVariable}". The "title=" syntax seems to only work with a hard-coded string.

So, what's the best way to display a tooltip when you have, say a list in a loop that populates a drop down list on a JSP page when the population mechanism is a JSTL loop?

Thanks in advance for any suggestions.

Mike
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
First, the "${}" syntax is EL (Expression Language) not JSTL.

Second, it doesn't make any difference what server side mechanism you use to create the text. The results of JSTL, Scriptlets, EL, Perl, PHP, ASP, etc... is text that gets sent down to the browser.

If your tooltips are not working, the first step toward debugging them would be to use your browser's "view source" option to see exactly what's being sent. From there you should have a good idea where to look.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!