aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes page 494 HFSJ Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "page 494 HFSJ" Watch "page 494 HFSJ" New topic
Author

page 494 HFSJ

Renu Radhika
Ranch Hand

Joined: Oct 21, 2005
Posts: 243
In page 494 HFSJ says attributes send to jsp:include using jsp aram are request parameters and and can be accessed when we are back from the included page whereas tag file attributes have page scope so wont be available outside the included page.But in the topic on jsp:include it says parameters send to include are not available outside the included page.Which is right?
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

New parameters that you pass to include/forward will not be accessible outside those tags.


[My Blog]
All roads lead to JavaRanch
Renu Radhika
Ranch Hand

Joined: Oct 21, 2005
Posts: 243
Then I guess this should be added to errata of HFSJ?Also then whats the difference between attributes to tags and params to include?
Renu Radhika
Ranch Hand

Joined: Oct 21, 2005
Posts: 243
Santou,Please help me in this
Aniket Patil
Ranch Hand

Joined: May 02, 2006
Posts: 218
attributes send to jsp:include using jsp : param are request parameters and and can be accessed when we are back from the included page


Where did you find this on Page 494?


SCJP 5.0 | SCWCD 1.4 <br /> <br />If you don't know where you are going, any road will take you there!
shivender Devarakonda
Greenhorn

Joined: Jul 01, 2007
Posts: 2
I think you are wrong. It was clearly said that <<jsp : param >> is used to set the parameters in request. so it should be available after include tag also. Please check HFSJ 415 include review...... it says that you can re-set a parameter value that is already there in the request so it clearly says it operates directly on request object. I, my self never used extensively this feature
any comments???
-Shivender
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

That's when I have no choice but pull out the spec :

When doing jsp:include or jsp:forward, the included page or forwarded page will see the original request object, with the original parameters augmented with the new parameters, with new values taking precedence over existing values when applicable. The scope of the new parameters is the jsp:include or jsp:forward call; i.e. in the case of an jsp:include the new parameters (and values) will not apply after the include. This is the same behavior as in the ServletRequest include and forward methods (see Section 8.1.1 in the Servlet 2.4 specification).
Renu Radhika
Ranch Hand

Joined: Oct 21, 2005
Posts: 243
Santou,
Then wahts the difference between attributes to tags and params to include?This is the advantage mentioned for attributes to tags in HFSJ
Renu Radhika
Ranch Hand

Joined: Oct 21, 2005
Posts: 243
Can anyone please help me with this?
Renu Radhika
Ranch Hand

Joined: Oct 21, 2005
Posts: 243
Santou,
Could you please help me in this?
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

Then wahts the difference between attributes to tags and params to include?

Attributes : the tag itself will receive the values.
Params : the page included will receive the values.
Sorry, I don't understand what is bothering you.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: page 494 HFSJ