William Nielsen

Greenhorn
+ Follow
since Dec 22, 2009
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by William Nielsen

David Newton wrote:You don't. You'd need to write a custom tag to do that. This is trivial in JSP 2.0+.

Why would you need to do this?



I am integrating a search engine with an app that uses custom tags as well as JSTL and Struts tags for presentation logic. What I need is the search engine index task to "see" what the expression name is for all tags so I can have the search engine "remember" who should see a text blurb or not. In other words I don't want the index task to index "Text A" for someone who isn't supposed to see "Text A". My plan was to have a index 'super user' ID that evaluated to "true" for the custom tags but write out a comment or reserved text before and after the tags so the index engine remembers what security tag governs that block.
14 years ago
I am faced with an interested design issue. In a JSP page, I need to write out a special text string along with the "name" attribute for JSTL and Struts logic tags (e.g., c:if, c:when, etc...) for all start and end tags.
So, for example:

Should render the following when displayed:


How would I override/intercept the JSTL and Struts tag logic in order to inject/override the (I assume) doStartTag / doEndTag logic? I've been googling and thinking about this for days to no avail. Please help!
14 years ago