This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

request.getAttribute and request.getParameter

 
Brusk Baran
Ranch Hand
Posts: 132
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It seems that even though I explicitly equate the attribute to null in a forwarded jsp page (which will forward itself again to the calling page later); the calling page still has access to the parameters sent to it via a form.
Attribute names @ request scope and the parameter names (which are naturally in the request scope) refer not to the same thing actually ??
It is confusing...
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64182
83
IntelliJ IDE Java jQuery Mac Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Parameters and attributes are completely separate items.
Parameters are generated by submission parameters (be they form elements or query string parameters), while attributes are placed onto a request under code control. They really have not a thing to do with each other.
bear
 
Brusk Baran
Ranch Hand
Posts: 132
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ja Bear,
thx, I thought they were the same since both reside on the request scope; and did a small design on this a priori assumption; on which some request parameters wander around strangely.
But handled them appropriately after your post. Created a new req. attribute and check it afterwards in the forwarded pages.
Merci,
B. Baran
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic