The clue is....you haven't read the manual.

You are creating a target in your JSP called "myPage".  Your struts-config 
doesn't 
define this target anywhere.  It needs to be in your action-mappings.  Also, 
because the 
target includes a form you need to specify the "NAME" attribute to identify a 
form-bean 
entry which ties it all back to your pojo.  I'll bet your totally lost now and 
just wishing 
somebody would tell you what to write.... (been there, done that).

There are lots of example Struts apps around that work.  Download one of these 
and 
use it for reference.  I started with a forum example from John Topley, it 
seemed to be 
well written and even looking back now I think it was pretty good.  You will 
find it at:
http://www.sitepoint.com/article/struts-first-steps

Cheers
mc

On 2 Nov 2005 at 12:12, Jacob Wilson wrote:

> Hi Dave -
>  
> Even without the name attribute it is the same !!!
>  
> <html:form method="post" action="myPage"> 
>  
> Here is my struts-config
>  
> <struts-config>
>   <form-beans>
>     <form-bean name="RoleForm" type="com.ui.forms.FormnnName" />
>   </form-beans>
>   <global-forwards>
>     <forward name="error" path="/iam_error.jsp" />
>     <forward name="invalidUser" path="/iam_invalid_user.jsp" />
>   </global-forwards>
>   <action-mappings>
>      <action input="/iam_admin_role_my_roles.jsp" name="FormName" 
path="/myRoles.do" scope="request" type="com.ui.actions.MyPage"/>
> </action-mappings>
>   <!-- Message Resources -->
>   <message-resources parameter="ApplicationResources" null="false"/>
>   <plug-in className="org.apache.struts.tiles.TilesPlugin">
>     <set-property property="definitions-config" 
> value="/WEB-INF/tiles-defs.xml" />
>   </plug-in>
>   <plug-in className="org.apache.struts.validator.ValidatorPlugIn">
>     <set-property property="pathnames" 
> value="/WEB-INF/validator-rules.xml,/WEB-
INF/validation.xml" />
>   </plug-in>
> </struts-config>
>  
>  
> Any clues???
>  
> Thanks
> Jacob
> 
> Dave Newton <[EMAIL PROTECTED]> wrote:
> Jacob Wilson wrote:
> 
> >I have a problem with my jsps after migrating my application from tomcat to 
Websphere. I use the struts-html taglibs in my jsps. When I use the normal html 
form 
tag like below, everything looks fine and the page gets displayed without 
problems.
> > 
> >
> > 
> >When I use the struts-html taglib like below, the jsp that shows up on the 
> >browser is 
totally empty....
> > 
> > 
> > 
> >I had made sure that the action is present in struts-config.xml. Also, when 
> >I say 
action="myPage" in the form tag does not work.
> > 
> >
> I am suspicious of the "name" attribute. Or at least I am now that I 
> figured out what the difference between the two JSP chunks actually was.
> 
> I've never used "name" in html:form (I didn't even know you could); 
> "name" is created by html:form using the "action" attribute and the 
> "name" attribute in the action's configuration.
> 
> But you didn't include any struts config info, so who knows.
> 
> Dave
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
> 
>               
> ---------------------------------
>  Yahoo! FareChase - Search multiple travel sites in one click.  



FOCUS Computing - web design
Mob: 0415 24 26 24
[EMAIL PROTECTED]
http://www.focus-computing.com.au




-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.362 / Virus Database: 267.12.7/154 - Release Date: 1/11/2005


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

Reply via email to