How do I reference a Custom Page from within another Custom Page?

I want to call a Custom Page in my deployment from within another Custom Page. The standard method of referencing a web page from within a JSP is to use the action attribute; how do I configure the action attribute if the target page is a Custom Page?

 

To configure the action attribute requires two steps: obtaining the URL of the destination page, and then referencing the URL in the action attribute.

For example:

  1. Obtaining the URL of the destination page (replace destinationPage.jsp with the file name of the target JSP, and customFolder with the name of the folder in which you store your Custom Pages):
<%
final String DESTINATION_URL = request.getServletPath()+"/jsp/custom/customFolder/destinationPage.jsp;
jsessionid="+session.getId();
%>
  1. Referencing the URL in the action attribute:
<form action="<%=DESTINATION_URL%>">
...
</form>

xMatters Reference

JDN-2126 Originally created by Don Clark

Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.
Powered by Zendesk