File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes Getting parameters from a SimpleTagSupport derived handler Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Getting parameters from a SimpleTagSupport derived handler" Watch "Getting parameters from a SimpleTagSupport derived handler" New topic
Author

Getting parameters from a SimpleTagSupport derived handler

Karl Krasnowsky
Ranch Hand

Joined: Jan 16, 2009
Posts: 97
I thought this would be relatively simple, but now I'm not so sure.
In a doTag() block of my handler I want to detect if a certain parameter had been passed into the page via url, e.g.,



I want to find the showkey parameter, but I don't see anything in the SimpleTagSupport that would provide such access.

There must be a way to do this?

Thanks,
K2


[SCJP 6]
[SCBCD in process]
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61766
    
  67

All this information is on the request, which can be obtained from the PageContent.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Karl Krasnowsky
Ranch Hand

Joined: Jan 16, 2009
Posts: 97
Bear Bibeault wrote:All this information is on the request, which can be obtained from the PageContent.


Yea, got that, but how do you get to the PageContent from the SimpleTagSupport? [before I searched coderanch]

Okay... so I found a reply from you for this very question a real long time ago here:

http://www.coderanch.com/t/288360/JSP/java/SimpleTagSupport

I should have done a bit more searching...

thanks!
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61766
    
  67

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Getting parameters from a SimpleTagSupport derived handler