Thats a deprecated class. (Servlet API 2.3) Just use request.getRequestURL(); -Tim
-----Original Message----- From: Michael Vincent [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 03, 2002 10:51 AM To: [EMAIL PROTECTED] Subject: Re: Getting full URL or Protocol in JSP page? Thanks. I actually got the URL with HttpUtil.getRequestURL(request). -----Original Message----- From: Shahata, Ashraf [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 03, 2002 10:52 AM To: [EMAIL PROTECTED] Subject: Re: Getting full URL or Protocol in JSP page? The following code retrieves the request headers that are passed when a template is requested: --------------------------------Start--------------------------------------- --- <%@ page language="java" import="java.util.*" %> <body bgcolor="white"> <font color="red"> <% out.println("<h3>" + "Header values for this request" + "</h3>"); out.println("<table border=0>"); Enumeration e = request.getHeaderNames(); while (e.hasMoreElements()) { String headerName = (String)e.nextElement(); String headerValue = request.getHeader(headerName); out.println("<tr><td bgcolor=\"#CCCCCC\">" + headerName); out.println("</td><td>" + headerValue + "</td></tr>"); } out.println("</table>"); %> --------------------------------End----------------------------------------- ---- -----Original Message----- From: Michael Vincent [mailto:[EMAIL PROTECTED]] Sent: 03 April 2002 16:27 To: [EMAIL PROTECTED] Subject: Getting full URL or Protocol in JSP page? In ASP it is possible to get the fully qualified URL or protocol of a page with the Request.ServerVariables collection. Is this possible in JSP? I did not see anything that would help in the request object. It will only give me the relative URL. Thanks! -mike. ==========================================================================To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com ==========================================================================To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com