• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

need of getPathInfo()

 
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi all,
can somebody explain me need of having getPathInfo() method in the HttpServletRequest object?
from the API i get that it is to get cgi variable PATH_INFO but then why we need PATH_INFO variable if we can achieve the same effect using parameters you know...
what i am missing?
is it the case that PATH_INFO was the earlier support before the support to parameters in the URL and now to maintain backword compatibiltiy servers support PATH_INFO variable?
please help me.
thanks.
maulin
 
Maulin Vasavada
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
alright,
i am realizing something.
PATH_INFO variable is used to form a value for PATH_TRANSLATED variable by the "web server" to get the physical path for the virtual path in PATH_INFO variable.
now as this is done by the web browser the application script is free of doing any processing and can directly access the PATH_TRANSLATED which makes the application script task little easier, right? so thats the purpose of having PATH_INFO instead embedding such information in the query string. if that information is in the query string then the application script needs to process it...
am i right in this derivation?
regards
maulin
reply
    Bookmark Topic Watch Topic
  • New Topic