This week's book giveaway is in the Performance forum.
We're giving away four copies of The Java Performance Companion and have Charlie Hunt, Monica Beckwith, Poonam Parhar, & Bengt Rutisson on-line!
See this thread for details.
Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Method getRequestURL() not found in javax.servlet .http.HttpRequest???

 
Stefan Elfvinge
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
Big mystery- why does my compiler say that above method can't be found in the above package/interface??? Obviously the compiler has access to the jarfile containing the code since the errorreport prints the fully qualified name???
The method getRequestURI() is found, but not the other one...
Anyone?
 
Anthony Villanueva
Ranch Hand
Posts: 1055
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check your servlet.jar. There is NO getRequestURL() found in javax.servlet.http.HttpRequest in the Servlet 2.2 version.
 
Stefan Elfvinge
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yep, I had an old API...
Thanks and as we say in Sweden- "Glad midsommar!"
 
Maulin Vasavada
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
u could use
HttpUtils.getRequestURL(request) instead i guess..
regards
maulin
 
Rene Larsen
Ranch Hand
Posts: 1179
Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
In the Servlet 2.2 API the method 'getRequestURI()' is in:

/Rene
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic