| Author |
Parameters and JSP includes
|
Eman Adenola
Greenhorn
Joined: Apr 03, 2011
Posts: 27
|
|
Hello Again
I'm confused about something..
I have 2 pages..a home page and a search page.
In the home page, I included the search page
the homepage has the address
I want the search page to be able to read get variables from the address bar..that was why i include a <jsp:param>
so that in the search page i can just go
But instead of typing
in the search.jsp page..I accidentally typed the actual variable in the get
And it worked, it was only after I realized the slip! :S..
I thought when you send a form to a certain page..only that certain page should be able to read param values..hence home.jsp should only be able to read the get variables...That was i added the jsp:param
But if search page could read it..without sending a direct post or get request to it..does that mean the variables in the param are global?
Or is it because I included the search in the homepage so it was able to read directly the variables? I am going more for params variables are global..
Would be grateful if someone can clear this fog up.
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56177
|
|
|
Grab the JSP Spec and read up on the rules of dispatcher include.
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
Eman Adenola
Greenhorn
Joined: Apr 03, 2011
Posts: 27
|
|
em...ok this might sound like a ridiculous question...but where do I get that?
It probably contains lot of complicated stuff, doesn't it..? lol
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56177
|
|
See the JSP FAQ.
If you are writing JSP, you need to be familiar with the specification and how to look up information within it.
|
 |
Eman Adenola
Greenhorn
Joined: Apr 03, 2011
Posts: 27
|
|
very well, I shall.
Thanks for your help.
|
 |
 |
|
|
subject: Parameters and JSP includes
|
|
|