Click here to Skip to main content
15,893,266 members
Home / Discussions / Java
   

Java

 
GeneralRe: java_script_autorefresh Pin
Richard MacCutchan22-May-10 6:53
mveRichard MacCutchan22-May-10 6:53 
GeneralRe: java_script_autorefresh Pin
iuli_3322-May-10 8:59
iuli_3322-May-10 8:59 
GeneralRe: java_script_autorefresh Pin
Richard MacCutchan22-May-10 9:36
mveRichard MacCutchan22-May-10 9:36 
Questionmaking a pic small?? Pin
AmbiguousName22-May-10 2:25
AmbiguousName22-May-10 2:25 
AnswerRe: making a pic small?? Pin
Richard MacCutchan22-May-10 4:34
mveRichard MacCutchan22-May-10 4:34 
QuestionGet complete URL address on address bar of browser Pin
tannghia21-May-10 20:14
tannghia21-May-10 20:14 
AnswerRe: Get complete URL address on address bar of browser Pin
Richard MacCutchan21-May-10 21:48
mveRichard MacCutchan21-May-10 21:48 
AnswerRe: Get complete URL address on address bar of browser Pin
Gerben Jongerius22-May-10 6:06
Gerben Jongerius22-May-10 6:06 
It depends a bit on how the page was called, but for as far as I know you can't get the complete URL simply by one call. You will need to construct it yourself as follows:
String url = request.getScheme() + "://" +
             request.getServerName() + "/" +
             request.getContextPath() + "/" +
             request.getServletPath() +
             (request.getQueryString() != null ? "?" + request.getQueryString() : "");


I haven't done a code check but this should work presuming you are in the servlet or JSP file and have the HttpServletRequest object available as 'request'. Which should be the default for JSP files and the .get() and .post() members in any servlet.
GeneralRe: Get complete URL address on address bar of browser Pin
tannghia22-May-10 17:36
tannghia22-May-10 17:36 
GeneralRe: Get complete URL address on address bar of browser Pin
Gerben Jongerius22-May-10 21:26
Gerben Jongerius22-May-10 21:26 
GeneralRe: Get complete URL address on address bar of browser Pin
tannghia23-May-10 2:03
tannghia23-May-10 2:03 
GeneralRe: Get complete URL address on address bar of browser Pin
Gerben Jongerius25-May-10 22:37
Gerben Jongerius25-May-10 22:37 
Questionjava game [modified] Pin
aleesya8818-May-10 5:26
aleesya8818-May-10 5:26 
QuestionExecutable jar Not Running on Mac OS. Pin
002comp17-May-10 20:53
002comp17-May-10 20:53 
AnswerRe: Executable jar Not Running on Mac OS. Pin
002comp19-May-10 2:00
002comp19-May-10 2:00 
GeneralRe: Executable jar Not Running on Mac OS. Pin
Richard MacCutchan19-May-10 2:31
mveRichard MacCutchan19-May-10 2:31 
GeneralRe: Executable jar Not Running on Mac OS. Pin
002comp19-May-10 2:56
002comp19-May-10 2:56 
AnswerRe: Executable jar Not Running on Mac OS. Pin
427748019-May-10 11:27
427748019-May-10 11:27 
GeneralRe: Executable jar Not Running on Mac OS. Pin
002comp19-May-10 19:37
002comp19-May-10 19:37 
Questionneed guidence Pin
sherry9917-May-10 20:03
sherry9917-May-10 20:03 
AnswerRe: need guidence Pin
Richard MacCutchan17-May-10 21:46
mveRichard MacCutchan17-May-10 21:46 
Questionsocket Pin
balakpn17-May-10 11:32
balakpn17-May-10 11:32 
AnswerRe: socket Pin
Richard MacCutchan17-May-10 21:48
mveRichard MacCutchan17-May-10 21:48 
QuestionHow to set java path in coding Pin
002comp14-May-10 18:43
002comp14-May-10 18:43 
AnswerRe: How to set java path in coding Pin
002comp14-May-10 21:39
002comp14-May-10 21:39 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.