A friendly place for programming greenhorns!
Big Moose Saloon
Search
|
Java FAQ
|
Recent Topics
Register / Login
Win a copy of
The Mikado Method
this week in the
Agile and other Processes
forum!
JavaRanch
»
Java Forums
»
Certification
»
Web Component Certification (SCWCD/OCPJWCD)
Author
Mock exam question on encodeURL
sid sree
Ranch Hand
Joined: Jun 28, 2007
Posts: 186
posted
Aug 03, 2007 16:24:00
0
Which of the following is an example of URL rewriting by using encodeURL(
String
url)
1)
http://localhost:8080/servlet/play;jsessionid=56
2)
http://localhost:8080/servlet/play
3 )
http://localhost:8080/servlet/play?jsessionid=56
4 ) None of the above
The answer given is 1 and 2
Why is the third one wrong ?? Is it that encodeURL(..) is always going to use ; instead of ?
Thanks
Michael Ku
Ranch Hand
Joined: Apr 20, 2002
Posts: 510
posted
Aug 03, 2007 17:10:00
0
the "?" denotes the start of the query string which has nothing to do with URL rewriting. Thaa is why it is not a correct answer
I agree. Here's the link:
http://aspose.com/file-tools
subject: Mock exam question on encodeURL
Similar Threads
problem with struts-config.xml
Installing servlet
Problem in opening my Servlet in the browser...
How to set conf file file
encodeURL and encodeRedirectURL
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter