Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Request.ServerVariables()

 
Sumon Mukherjee
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need the jsp equivalent of Request.ServerVariables() in asp. Please advise...
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ASP's getServerVariables method returns the combination of a lot of things such as form parameters, querystring parameters, HTTP headers, and some TCP information, as a single collection.

All of this information is available in the HttpServletRequest object but not all jumbled up in a single method like getServerVariables.

It wouldn't be difficult, to emulate getServerVaribles on your own using the request object.
 
Sumon Mukherjee
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Tried getURL(), getRequestURL(),getQueryString(), getPathInfo(), but no luck...
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65110
89
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Sumon Mukherjee:
but no luck...
That's not going to get you anywhere. What are you expecting and what are you getting? Making people pull teeth in order to help you isn't the best of strategies.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic