You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Karsten Krieg <kk...@intarsys.de> on 2005/02/15 09:26:38 UTC

Antwort: bean:include

Hi!

Why not just use jsp:include. There's nothing wrong with it. You can even
use a request attribute for setting the jsp page.

<jsp:include page="<%= includePage %>"/>

Regards
Karsten Krieg
intarsys consulting GmbH
----------------------------------------
Fon +49 (0)721 3 84 79 - 28
Fax +49 (0)721 3 84 79 - 60
e-mail kkrieg@intarsys.de
http://www.intarsys.de
----------------------------------------
"Iran! That's where the weapons of mass destruction were! It was a typo all
along!"

wo shi ni baba <wo...@yahoo.com> schrieb am 15.02.2005 03:54:38:

> Hi folks,
> I am new to struts, I am trying to get the equivalent
> of jsp:include in struts.  I tried
> <bean:include  id="top"  page="/Top.jsp" />
> this itself does not actually print the content.  what
> else do I need to do to get Top.jsp onto the screen?
> thanks in advance
>
>
>
>
> __________________________________
> Do you Yahoo!?
> The all-new My Yahoo! - What will yours do?
> http://my.yahoo.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: form bean exception -RESOLVED

Posted by Jonathan M Z <wo...@yahoo.com>.
I made a mistake in the Action mapping.
thank you all


--- Saul Qunming Yuan <yu...@dataanvil.com> wrote:

> Do you have the action mapping defined for logon.do
> in your struts-config
> file? what's it like?
> 
> 
> BTW, just a friendly reminder, you probably don't
> want to use that email
> id in this list, the audience are global. I happen
> to catch it and know
> what it means :-(
> 
> thanks,
> Saul
> 
> 
> 
> > hi folks,
> > I have a simple form in struts:
> > <html:form  action="logon.do" focus="userName">
> > <html:text property = "userName"/>
> > </html:form>
> > I get an exception when the jsp page is rendered
> > [Servlet Error]-[/Login.jsp]:
> > javax.servlet.jsp.JspException: Cannot retrieve
> > definition for form bean null
> > what's wrong?
> > thanks
> >
> >
> >
> > __________________________________
> > Do you Yahoo!?
> > The all-new My Yahoo! - What will yours do?
> > http://my.yahoo.com
> >
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> user-unsubscribe@struts.apache.org
> > For additional commands, e-mail:
> user-help@struts.apache.org
> >
> 
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@struts.apache.org
> For additional commands, e-mail:
> user-help@struts.apache.org
> 
> 



		
__________________________________ 
Do you Yahoo!? 
Take Yahoo! Mail with you! Get it on your mobile phone. 
http://mobile.yahoo.com/maildemo 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: form bean exception

Posted by Saul Qunming Yuan <yu...@dataanvil.com>.
Do you have the action mapping defined for logon.do in your struts-config
file? what's it like?


BTW, just a friendly reminder, you probably don't want to use that email
id in this list, the audience are global. I happen to catch it and know
what it means :-(

thanks,
Saul



> hi folks,
> I have a simple form in struts:
> <html:form  action="logon.do" focus="userName">
> <html:text property = "userName"/>
> </html:form>
> I get an exception when the jsp page is rendered
> [Servlet Error]-[/Login.jsp]:
> javax.servlet.jsp.JspException: Cannot retrieve
> definition for form bean null
> what's wrong?
> thanks
>
>
>
> __________________________________
> Do you Yahoo!?
> The all-new My Yahoo! - What will yours do?
> http://my.yahoo.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: form bean exception

Posted by Wendy Smoak <ja...@wendysmoak.com>.
From: "Jonathan M Z" <wo...@yahoo.com>
> I have a simple form in struts:
> <html:form  action="logon.do" focus="userName">
> <html:text property = "userName"/>
> </html:form>
> I get an exception when the jsp page is rendered
> [Servlet Error]-[/Login.jsp]:
> javax.servlet.jsp.JspException: Cannot retrieve
> definition for form bean null
> what's wrong?

Try it without the ".do":
  <html:form  action="logon"  ... >

If that doesn't work, post the relevant part of struts-config.xml.

-- 
Wendy Smoak

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


form bean exception

Posted by Jonathan M Z <wo...@yahoo.com>.
hi folks,
I have a simple form in struts:
<html:form  action="logon.do" focus="userName">
<html:text property = "userName"/>
</html:form>
I get an exception when the jsp page is rendered
[Servlet Error]-[/Login.jsp]:
javax.servlet.jsp.JspException: Cannot retrieve
definition for form bean null
what's wrong?
thanks


		
__________________________________ 
Do you Yahoo!? 
The all-new My Yahoo! - What will yours do?
http://my.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: bean:include

Posted by Wendy Smoak <ja...@wendysmoak.com>.
From: "wo shi ni baba" <wo...@yahoo.com>

> so essentially there's no replacement of jsp:include
> in struts, right?

I suppose you could use Tiles to do the same thing as a jsp:include, but if
all you need is a simple include, Tiles is overkill.

-- 
Wendy Smoak


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Antwort: Re: Antwort: bean:include

Posted by wo shi ni baba <wo...@yahoo.com>.
Hi thanks,
so essentially there's no replacement of jsp:include
in struts, right?


--- Karsten Krieg <kk...@intarsys.de> wrote:

> 
> Hi!
> 
> Nothing special here. Let's say you've an struts
> action like this:
> 
>         <action
>             name="variableForm"
>             path="/editVariable"
>             scope="request"
>            
>
type="de.intarsys.efselect.web.action.page.EditVariableAction"
>                   input="/variable.jsp"
>             validate="true">
>                   <forward name="next"
> path="/prepMatchFields.do" />
>                   <forward name="self"
> path="/prepShowValue.do" />
>         </action>
> 
> The referenced variable.jsp itself has a java
> scriptlet like this:
> <%
>       String typePage = "/variable/detail_" +
> container.getType() + ".jsp";
> %>
> 
> In my html-table of individual contents I just :
> 
>                         <div style="width:100%;
> height:100%;
> overflow:auto;">
>                               <jsp:include page="<%=
> typePage %>"/>
>                         </div>
> 
> So, Struts is not really involved.
> 
> Regards
> Karsten Krieg
> intarsys consulting GmbH
> ----------------------------------------
> Fon +49 (0)721 3 84 79 - 28
> Fax +49 (0)721 3 84 79 - 60
> e-mail kkrieg@intarsys.de
> http://www.intarsys.de
> ----------------------------------------
> "Iran! That's where the weapons of mass destruction
> were! It was a typo all
> along!"
> 
> wo shi ni baba <wo...@yahoo.com> schrieb
> am 15.02.2005 09:31:19:
> 
> > hi, thanks, but would you tell me how to do it in
> > struts?
> >
> > --- Karsten Krieg <kk...@intarsys.de> wrote:
> >
> > >
> > > Hi!
> > >
> > > Why not just use jsp:include. There's nothing
> wrong
> > > with it. You can even
> > > use a request attribute for setting the jsp
> page.
> > >
> > > <jsp:include page="<%= includePage %>"/>
> > >
> > > Regards
> > > Karsten Krieg
> > > intarsys consulting GmbH
> > > ----------------------------------------
> > > Fon +49 (0)721 3 84 79 - 28
> > > Fax +49 (0)721 3 84 79 - 60
> > > e-mail kkrieg@intarsys.de
> > > http://www.intarsys.de
> > > ----------------------------------------
> > > "Iran! That's where the weapons of mass
> destruction
> > > were! It was a typo all
> > > along!"
> > >
> > > wo shi ni baba <wo...@yahoo.com>
> schrieb
> > > am 15.02.2005 03:54:38:
> > >
> > > > Hi folks,
> > > > I am new to struts, I am trying to get the
> > > equivalent
> > > > of jsp:include in struts.  I tried
> > > > <bean:include  id="top"  page="/Top.jsp" />
> > > > this itself does not actually print the
> content.
> > > what
> > > > else do I need to do to get Top.jsp onto the
> > > screen?
> > > > thanks in advance
> > > >
> > > >
> > > >
> > > >
> > > > __________________________________
> > > > Do you Yahoo!?
> > > > The all-new My Yahoo! - What will yours do?
> > > > http://my.yahoo.com
> > > >
> > > >
> > >
> >
>
---------------------------------------------------------------------
> > > > To unsubscribe, e-mail:
> > > user-unsubscribe@struts.apache.org
> > > > For additional commands, e-mail:
> > > user-help@struts.apache.org
> > > >
> > >
> > >
> > >
> > >
> > >
> >
>
---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> > > user-unsubscribe@struts.apache.org
> > > For additional commands, e-mail:
> > > user-help@struts.apache.org
> > >
> > >
> >
> >
> >
> >
> > __________________________________
> > Do you Yahoo!?
> > All your favorites on one personal page ? Try My
> Yahoo!
> > http://my.yahoo.com
> >
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> user-unsubscribe@struts.apache.org
> > For additional commands, e-mail:
> user-help@struts.apache.org
> >
> 
> 
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@struts.apache.org
> For additional commands, e-mail:
> user-help@struts.apache.org
> 
> 



		
__________________________________ 
Do you Yahoo!? 
The all-new My Yahoo! - Get yours free! 
http://my.yahoo.com 
 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Antwort: Re: Antwort: bean:include

Posted by Karsten Krieg <kk...@intarsys.de>.
Hi!

Nothing special here. Let's say you've an struts action like this:

        <action
            name="variableForm"
            path="/editVariable"
            scope="request"
            type="de.intarsys.efselect.web.action.page.EditVariableAction"
                  input="/variable.jsp"
            validate="true">
                  <forward name="next" path="/prepMatchFields.do" />
                  <forward name="self" path="/prepShowValue.do" />
        </action>

The referenced variable.jsp itself has a java scriptlet like this:
<%
      String typePage = "/variable/detail_" + container.getType() + ".jsp";
%>

In my html-table of individual contents I just :

                        <div style="width:100%; height:100%;
overflow:auto;">
                              <jsp:include page="<%= typePage %>"/>
                        </div>

So, Struts is not really involved.

Regards
Karsten Krieg
intarsys consulting GmbH
----------------------------------------
Fon +49 (0)721 3 84 79 - 28
Fax +49 (0)721 3 84 79 - 60
e-mail kkrieg@intarsys.de
http://www.intarsys.de
----------------------------------------
"Iran! That's where the weapons of mass destruction were! It was a typo all
along!"

wo shi ni baba <wo...@yahoo.com> schrieb am 15.02.2005 09:31:19:

> hi, thanks, but would you tell me how to do it in
> struts?
>
> --- Karsten Krieg <kk...@intarsys.de> wrote:
>
> >
> > Hi!
> >
> > Why not just use jsp:include. There's nothing wrong
> > with it. You can even
> > use a request attribute for setting the jsp page.
> >
> > <jsp:include page="<%= includePage %>"/>
> >
> > Regards
> > Karsten Krieg
> > intarsys consulting GmbH
> > ----------------------------------------
> > Fon +49 (0)721 3 84 79 - 28
> > Fax +49 (0)721 3 84 79 - 60
> > e-mail kkrieg@intarsys.de
> > http://www.intarsys.de
> > ----------------------------------------
> > "Iran! That's where the weapons of mass destruction
> > were! It was a typo all
> > along!"
> >
> > wo shi ni baba <wo...@yahoo.com> schrieb
> > am 15.02.2005 03:54:38:
> >
> > > Hi folks,
> > > I am new to struts, I am trying to get the
> > equivalent
> > > of jsp:include in struts.  I tried
> > > <bean:include  id="top"  page="/Top.jsp" />
> > > this itself does not actually print the content.
> > what
> > > else do I need to do to get Top.jsp onto the
> > screen?
> > > thanks in advance
> > >
> > >
> > >
> > >
> > > __________________________________
> > > Do you Yahoo!?
> > > The all-new My Yahoo! - What will yours do?
> > > http://my.yahoo.com
> > >
> > >
> >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> > user-unsubscribe@struts.apache.org
> > > For additional commands, e-mail:
> > user-help@struts.apache.org
> > >
> >
> >
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> > user-unsubscribe@struts.apache.org
> > For additional commands, e-mail:
> > user-help@struts.apache.org
> >
> >
>
>
>
>
> __________________________________
> Do you Yahoo!?
> All your favorites on one personal page ? Try My Yahoo!
> http://my.yahoo.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Antwort: bean:include

Posted by wo shi ni baba <wo...@yahoo.com>.
hi, thanks, but would you tell me how to do it in
struts?

--- Karsten Krieg <kk...@intarsys.de> wrote:

> 
> Hi!
> 
> Why not just use jsp:include. There's nothing wrong
> with it. You can even
> use a request attribute for setting the jsp page.
> 
> <jsp:include page="<%= includePage %>"/>
> 
> Regards
> Karsten Krieg
> intarsys consulting GmbH
> ----------------------------------------
> Fon +49 (0)721 3 84 79 - 28
> Fax +49 (0)721 3 84 79 - 60
> e-mail kkrieg@intarsys.de
> http://www.intarsys.de
> ----------------------------------------
> "Iran! That's where the weapons of mass destruction
> were! It was a typo all
> along!"
> 
> wo shi ni baba <wo...@yahoo.com> schrieb
> am 15.02.2005 03:54:38:
> 
> > Hi folks,
> > I am new to struts, I am trying to get the
> equivalent
> > of jsp:include in struts.  I tried
> > <bean:include  id="top"  page="/Top.jsp" />
> > this itself does not actually print the content. 
> what
> > else do I need to do to get Top.jsp onto the
> screen?
> > thanks in advance
> >
> >
> >
> >
> > __________________________________
> > Do you Yahoo!?
> > The all-new My Yahoo! - What will yours do?
> > http://my.yahoo.com
> >
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> user-unsubscribe@struts.apache.org
> > For additional commands, e-mail:
> user-help@struts.apache.org
> >
> 
> 
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@struts.apache.org
> For additional commands, e-mail:
> user-help@struts.apache.org
> 
> 



		
__________________________________ 
Do you Yahoo!? 
All your favorites on one personal page � Try My Yahoo!
http://my.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org