[Logo]
Forums Register Login
hot to get the server name using jsp
hi

i wanted to get the file path along with the server name using jsp
can i get he server name using jsp
how can this be done

waiting for your reply



regards
santosh
I am not sure if you really need the server name but this is the way you get it. Use request.getServerName().

If you need the context path to be appended to your file, then usen request.getContextPath()
Are we home yet? Wait, did we forget the tiny ad?
Why should you try IntelliJ IDEA ?
https://coderanch.com/wiki/696337/IntelliJ-IDEA


This thread has been viewed 2718 times.

All times above are in ranch (not your local) time.
The current ranch time is
Jul 20, 2018 16:06:46.