- This topic has 1 reply, 2 voices, and was last updated 21 years, 1 month ago by support-michael.
-
AuthorPosts
-
Bill WinspurMemberI’m using ME to develop a struts/tiles app and had no problems with the following page-welcome.jsp.
<%@ taglib uri=”/WEB-INF/struts-tiles.tld” prefix=”tiles” %>
<tiles:insert page=”myLayout.jsp” flush=”true”>
<tiles:put name=”title” value=”tbd” />
<tiles:put name=”body” value=”body-welcome.jsp” />
<tiles:put name=”footer” value=”footer.jsp” />
<tiles:put name=”menu” value=”menu.jsp” />
</tiles:definition>The specified put jsp’s, and the underlying layout.jsp produced correctly formatted browser presentations
Then I tried to refactor my pages using using the apache <tiles:definition> tag. The page-welcome.jsp code in question follows:
<%@ taglib uri=”/WEB-INF/struts-tiles.tld” prefix=”tiles” %>
<tiles:definition id=”wynnContent” page=”wynnon-layout.jsp”>
<tiles:put name=”title” value=”tbd” />
<tiles:put name=”body” value=”tbd” />
<tiles:put name=”footer” value=”footer.jsp” />
<tiles:put name=”menu” value=”menu.jsp” />
</tiles:definition>
<tiles:insert beanName=”wynnContent” beanScope=”application” >
<tiles:put name=”title” value=”Welcome To Wynnon” />
<tiles:put name=”body” value=”body-welcome.jsp” />
</tiles:insert>Deploy to the server seems to go OK, but execution of the app produces the following Exception page on the browser:
500 Internal Server Error:
javax.servlet.jsp.JspException: Error – Tag Insert : No value defined for bean ‘wynnContent’ with property ‘null’ in scope ‘application’.
at org.apache.struts.taglib.tiles.InsertTag.processBean(InsertTag.java:683)
at org.apache.struts.taglib.tiles.InsertTag.createTagHandler(InsertTag.java:513)
at org.apache.struts.taglib.tiles.InsertTag.doStartTag(InsertTag.java:460)
at /page-welcome.jsp._jspService(/page-welcome.jsp.java:140)
at com.orionserver[Orion/2.0.2 (build 11157)].http.OrionHttpJspPage.service(.:70)
at com.evermind[Orion/2.0.2 (build 11157)]._ay._rkb(.:5741)
at com.evermind[Orion/2.0.2 (build 11157)].server.http.JSPServlet.service(.:31)
at com.evermind[Orion/2.0.2 (build 11157)]._cub._pod(.:521)
at com.evermind[Orion/2.0.2 (build 11157)]._cub._bmc(.:177)
at com.evermind[Orion/2.0.2 (build 11157)]._cub.forward(.:147)
at org.apache.struts.actions.ForwardAction.execute(ForwardAction.java:158)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:446)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:266)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1292)
at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:492)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:195)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:309)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
at com.evermind[Orion/2.0.2 (build 11157)]._cub._pod(.:521)
at com.evermind[Orion/2.0.2 (build 11157)]._cub._bmc(.:177)
at com.evermind[Orion/2.0.2 (build 11157)]._ax._ltc(.:666)
at com.evermind[Orion/2.0.2 (build 11157)]._ax._uab(.:191)
at com.evermind[Orion/2.0.2 (build 11157)]._bf.run(.:62)I’m running XP with Orion 2 and ME on the same workstation. Is there
something special one must do to handle <tiles.definition …> tags,
in the struts servlet, or with the orion config? I’ve enabled the tiles
plugin in my struts-config, and I can’t see anything wrong with my
tag code (which is highly likely to be the problem, I admit).Any assistance will be much appreciated.
Bill.
support-michaelKeymasterMy Tiles knowledge is minimal. So you Tiles experts please chime in. From the stacktrace –
javax.servlet.jsp.JspException: Error – Tag Insert : No value defined for bean ‘wynnContent’ with property ‘null’ in scope ‘application’
I would start researching the tiles:insert tag for more background. Looks like the wynnContent bean is not defined at runtime.
<tiles:insert beanName=”wynnContent” beanScope=”application” >
<tiles:put name=”title” value=”Welcome To Wynnon” />
<tiles:put name=”body” value=”body-welcome.jsp” />
</tiles:insert>Tiles tags API is defined here:
http://jakarta.apache.org/struts/userGuide/struts-tiles.html#insertTiles HOW-TO info defined here – see resources at bottom of page:
http://jakarta.apache.org/struts/userGuide/dev_tiles.htmlMichael
MyEclipse Support -
AuthorPosts