betweenGo

JSTL for current URI

by Frank Kim on May.27, 2008, under JSTL

I was wondering how do get the current URI using JSTL and found this forum thread, JSTL EL for current page URL?.

If you want the actual URI of the JSP that is being rendered:

<c:out value="${pageContext.request.requestURI}"/>

If you want the original URI, which is probably the case, then:

<c:out value="${requestScope['javax.servlet.forward.request_uri']}"/>


  • Share/Bookmark

Related posts:

  1. Get JSTL Vars from PageContext
  2. Testing Which Page Loaded your JSP Page Fragment
  3. Upgrading to JSTL 1.1
  4. JSP redirect to another page
  5. Accessing RepositoryItems with JSTL

:, ,

Leave a Reply

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!