You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Nik Malenovic <nm...@msn.com> on 2001/07/31 02:00:13 UTC
Wrong ordering of rendered html elements when using templates under WAS 3.5.x
Hello personable people,
We've got a live one over here - using templates under WebSphere 3.5.4
(don't ask) with struts 1.0 (plus a fix or two that is required to get
struts functioning properly under WAS3.5.x) produces misordered rendered
html elements.
Here's what I mean:
Actors:
-------
Home.jsp
Home_content.jsp
Home_template.jsp
Home.jsp:
---------
[<%@ taglibs here %> ]
<!-- home.jsp:My Title -->
<template:insert template="home_template.jsp">
<template:put name="title" direct="true">My Title</template:put>
<template:put name="content" content="home_content.jsp" />
</template:insert>
Home_content.jsp:
------------------
[<%@ taglibs here %> ]
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>foo</td>
</tr>
</table>
Home_template.jsp
------------------
[<%@ taglibs here %> ]
<html:html locale="true">
<head>
<title><template:get name="title" /> </title>
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0"
marginwidth="0" marginheight="0">
<table width="100%" border="0" cellspacing="0" cellpadding="0"
height="24">
<tr>
SOME MORE WILD TEXT HERE
</tr>
</table>
<!-- begin content -->
<template:get name="content" />
<!-- end content -->
</body>
</html:html>
Output of glorious home.jsp hosted by WAS3.5.x (notice out of order
rendering!):
------------------------------------------------------------------------
-----
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>foo</td>
</tr>
</table>
<html lang="en">
<head>
<title>
My Title
</title>
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0"
marginwidth="0" marginheight="0">
<table width="100%" border="0" cellspacing="0" cellpadding="0"
height="24">
<tr>
SOME MORE WILD TEXT HERE
</tr>
</table>
<!-- begin content -->
<!-- end content -->
</body>
</html>
<!-- home.jsp:My Title -->
See the problem? :-) I'd appreciate anyone with a clue to send me one.
Thanks,
Nik
--
Nik Malenovic <ma...@msn.com>