I\'ve go an absolute URL in my JavaScript that I have hard coded for window.location.
I don\'t want to have to change this every time I am testing my app. In PHP I w
What you need is:
request.getServerName()
An example:
<% String path = request.getContextPath(); String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"; %>