hi crisalyn,

        i had followed ur instruction and the pages do come out find.
however, when i do a request.getRequestURI() to get the url for the
current page, the value returned was
"http://localhost:8080/managenewsletters/newsletter_display_default.jsp";
instead of "http://localhost:8080/admin/showNewsletter.do";

        I do not want to show the JSP page used and this problem occurs
when Weblogic 6.1 is used as the web server. I do not get this result
when I tested the page on iPlanet.

        any pointers?

+trish

-----Original Message-----
From: Crisalyn Ramos [mailto:[EMAIL PROTECTED]]
Sent: Thursday, December 27, 2001 9:50 PM
To: Struts Users Mailing List
Subject: Re: How do display a *.do as the URL?


Tricia,

I assume that admin is your context path? Need not put your context path
in your
mapping as it is automatically appended.

This is how your struts-config.xml file should look like:

<struts-config>

<!-- Your form bean definitions here -->

<form-beans>
     <form-bean
          name="newsletterForm"
          type="test.actions.ShowNewslettersActionForm">
     </form-bean>
</form-beans>

<!-- Action Mappings here -->

<action-mappings>

        <action
                path="/showNewsletters"
                type="test.actions.ShowNewslettersAction"
                name="newsletterForm"
                scope="request"
                input="/mainMenu.jsp">
        <forward
                name="success"
            path="/managenewsletters/newsletter_display_default.jsp"/>
       </action>
<action-mappings>
</struts-config>

then call your application like:
http://localhost:8080/admin/showNewsletter.do

Hope this one helps.


thanks,
Cris




Tricia Ong Cheah Yen wrote:

> Hi,
>         I'm unable to have a url that appears in the client
web-browser
> address bar
> of the sort: http://localhost:8080/admin/showNewsletter.do
>
> but the url that i'm seeing is:
>
http://localhost:8080//admin/managenewsletters/newsletter_display_defaul
> t.jsp
>
> how can i accomplish this?
>         <action path="/admin/managenewsletters/showNewsletters"
>                 type="test.actions.ShowNewslettersAction"
> name="newsletterForm" scope="request"
>                 input="/admin/mainMenu.jsp">
>                 <forward name="success"
>
> path="/admin/managenewsletters/newsletter_display_default.jsp"/>
>         </action>
>
>         <!-- Action Servlet Mapping in web.xml -->
>         <servlet-mapping>
>                 <servlet-name>action</servlet-name>
>                 <url-pattern>*.do</url-pattern>
>         </servlet-mapping>
> TIA
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to