Skip to Content
author's profile photo Former Member
Former Member

How to call one JSP from another JSP

Hi,

I am trying to popup a jsp from another JSP.

When I use the url(to pop)componentRequest.getPrivateResourcePath()+"/pagelet/newPage.jsp"; I get Page cannot be dispayed error , You are not authorized to view this page.

Any ideas??

Any help is highly appreciated.

Thanks

Markandeya

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Mar 26, 2004 at 09:49 AM

    Hi,

    if i use IResource to get the URL of the page , then also i am getting same error.

    I need to call a popup jsp page onClientClick event of the button.

    Any ideas??

    Any help is highly appreciated.

    Thanks

    Markandeya

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Mar 26, 2004 at 09:52 AM

    Hi,

    if i use IResource to get the URL of the page , then also i am getting same error.

    I need to call a popup jsp page onClientClick event of the button.

    Any ideas??

    Any help is highly appreciated.

    Thanks

    Markandeya

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi,

      Call the jsp using a property file.Following code will help..

      IResource jspResource=componentRequest.getResource(IResource.JSP, "pagelet/File.jsp");

      String strComponentName=jspResource.getResourceInformation().getComponent();

      strUrl = componentRequest.createPageURL(strComponentName + ".PropertyFile");

      In the property file put ComponentType as jspNativie and the name of the jsp file name.

      Then open strUrl from the javascript.

      Vivek

  • author's profile photo Former Member
    Former Member
    Posted on Mar 26, 2004 at 11:40 AM

    Thank u very much Vivek,

    Pl let me have exact code in property file.

    ComponentType=jspNative

    jspName=custSearch.jsp

    Thanks

    Markandeya

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.