Hey Adam! You might be onto something here! When a zip code is entered, the "ajax" portion %{zipUrl} is fetching the zip info from a database and populating the fields that the DIV is supposed to include in the form. I have programmed a bunch of JSP's using this technique with XmlHttpObject! Do you suppose S2 does not allow it?
Thanks Scott On 3/14/07, Adam Ruggles <[EMAIL PROTECTED]> wrote:
Hi Stanlick, I think I know whats going on here. Whatever %{zipUrl} in the DIV's href property is pointing to is generating the bad HTML. This part: <LABEL class=label for=user_zip_city>City:</LABEL></TD> <TD><INPUT id=user_zip_city size=40 value=Edwardsville name=user.zip.city> </TD></TR><TR><TD class=tdLabel><LABEL class=label for=user_zip_state>State:</LABEL></TD> <TD><INPUT id=user_zip_state size=2 value=IL name=user.zip.state> </TD></TR> Is what is being pulled in from your %{zipUrl}. [EMAIL PROTECTED] wrote: > Hey Dave, how about *you* disregard this thread and allow someone else to > respond. This issue is obviously not a good match for your skills. > > Now then, I'm interested in discovering why an S2 form is generating > ill-formed HTML. I have tried each theme, and I get different > results, but > never reasonable output. Again, I am including my form and the resulting > generated HTML: > > =========================== > > <s:url id="zipUrl" value="http://localhost:8080/dsms/ZipCode.action" /> > > <s:form theme="xhtml" action="register" method="post" id="registerForm"> > <s:textfield name="user.username" value="%{user.username}" > label="%{getText('user.username')}" size="40" labelposition="right" /> > <s:textfield name="user.password" value="%{user.password}" > label="%{getText('user.password')}" size="40" /> > <s:textfield name="user.firstName" value="%{user.firstName}" > label="%{getText('user.firstName')}" size="40" /> > <s:textfield name="user.middleName" value="%{user.middleName}" > label="%{getText('user.middleName')}" size="40" /> > <s:textfield name="user.lastName" value="%{user.lastName}" > label="%{getText('user.lastName')}" size="40" /> > <s:textfield name="user.zip.zip" value="%{user.zip.zip}" > label="%{getText('user.zip')}" size="10" > onblur="javascript:dojo.event.topic.publish('zipEnteredTopic')" /> > <s:div autoStart="false" formId="registerForm" theme="ajax" > id="zipDiv" listenTopics="zipEnteredTopic" href="%{zipUrl}" /> > <s:submit value="%{getText('label.save')}" /> > </s:form> > =========================== > > <HTML xmlns:v = > "urn:schemas-microsoft-com:vml"><HEAD><TITLE>Register</TITLE> > <STYLE>v\:* { > BEHAVIOR: url(#default#VML) > } > </STYLE> > > <SCRIPT src="javascript:'dojo.html.createExternalElement=function(doc, > tag){ > return doc.createElement(tag); }'"></SCRIPT> > > <STYLE type=text/css>.dojoLayoutContainer { > DISPLAY: block; POSITION: relative > } > BODY .dojoAlignTop { > OVERFLOW: hidden; POSITION: absolute > } > BODY .dojoAlignBottom { > OVERFLOW: hidden; POSITION: absolute > } > BODY .dojoAlignLeft { > OVERFLOW: hidden; POSITION: absolute > } > BODY .dojoAlignRight { > OVERFLOW: hidden; POSITION: absolute > } > BODY .dojoAlignClient { > POSITION: absolute > } > .dojoAlignClient { > OVERFLOW: auto > } > </STYLE> > </HEAD> > <BODY><LINK href="/dsms/struts/xhtml/styles.css" type=text/css > rel=stylesheet> > <SCRIPT language=JavaScript type=text/javascript> > // Dojo configuration > djConfig = { > baseRelativePath: "/dsms/struts/dojo", > isDebug: true, > bindEncoding: "UTF-8", > debugAtAllCosts: true // not needed, but allows the Venkman > debugger > to work with the includes > }; > </SCRIPT> > > <SCRIPT language=JavaScript src="/dsms/struts/dojo/dojo.js" > type=text/javascript></SCRIPT> > > <SCRIPT src="/dsms/struts/dojo/src/debug.js" > type=text/javascript></SCRIPT> > > <SCRIPT src="/dsms/struts/dojo/src/browser_debug.js" > type=text/javascript></SCRIPT> > > <SCRIPT language=JavaScript src="/dsms/struts/simple/dojoRequire.js" > type=text/javascript></SCRIPT> > > <SCRIPT type=text/javascript>dojo.hostenv._global_omit_module_check = > false;</SCRIPT> > > <SCRIPT language=JavaScript src="/dsms/struts/ajax/dojoRequire.js" > type=text/javascript></SCRIPT> > <TEXTAREA id=dojo.widget.RichText.savedContent style="DISPLAY: none; > LEFT: > -100px; OVERFLOW: hidden; WIDTH: 3px; POSITION: absolute; TOP: -100px; > HEIGHT: 3px"></TEXTAREA> > <SCRIPT type=text/javascript>dojo.hostenv._global_omit_module_check = > false;</SCRIPT> > > <SCRIPT language=JavaScript src="/dsms/struts/CommonFunctions.js" > type=text/javascript></SCRIPT> > > <SCRIPT src="js/scripts.js" type=text/javascript></SCRIPT> > > <TABLE width="100%" border=0> > <TBODY> > <TR> > <TD><IMG src=".\image\logo.jpg"> The User in Session: </TD> > <TR> > <TD><FONT color=#808080 size=7>Dynamic Skills Management System > </FONT></TD> > <TR> > <TD><A href="/dsms/login!input.action">Logon </A> <A > href="/dsms/course!input.action">Courses</A> <A > href="/dsms/register!input.action">Register > </A></TD></TR></TBODY></TABLE> > <FORM id=registerForm name=register onsubmit="return true;" > action=/dsms/register.action method=post> > <TABLE class=wwFormTable> > <TBODY> > <TR> > <TD class=tdLabel><LABEL class=label for=registerForm_user_username>User > Name:</LABEL></TD> > <TD><INPUT id=registerForm_user_username size=40 name=user.username> > </TD></TR> > <TR> > <TD class=tdLabel><LABEL class=label > for=registerForm_user_password>Password:</LABEL></TD> > <TD><INPUT id=registerForm_user_password size=40 name=user.password> > </TD></TR> > <TR> > <TD class=tdLabel><LABEL class=label > for=registerForm_user_firstName>First > Name:</LABEL></TD> > <TD><INPUT id=registerForm_user_firstName size=40 name=user.firstName> > </TD></TR> > <TR> > <TD class=tdLabel><LABEL class=label > for=registerForm_user_middleName>Middle > Name:</LABEL></TD> > <TD><INPUT id=registerForm_user_middleName size=40 name=user.middleName> > </TD></TR> > <TR> > <TD class=tdLabel><LABEL class=label for=registerForm_user_lastName>Last > Name:</LABEL></TD> > <TD><INPUT id=registerForm_user_lastName size=40 name=user.lastName> > </TD></TR> > <TR> > <TD class=tdLabel><LABEL class=label for=registerForm_user_zip_zip>Zip > Code:</LABEL></TD> > <TD><INPUT id=registerForm_user_zip_zip onblur="javascript: > dojo.event.topic.publish('zipEnteredTopic')" size=10 value=62025 name= > user.zip.zip> </TD></TR> > <DIV id=zipDiv showError="true" listenTopics="zipEnteredTopic" href=" > http://localhost:8080/dsms/ZipCode.action" formId="registerForm" > autoStart="false" dojoType="struts:BindDiv"><LABEL class=label > for=user_zip_city>City:</LABEL></TD> <TD><INPUT id=user_zip_city size=40 > value=Edwardsville name=user.zip.city> </TD></TR><TR><TD > class=tdLabel><LABEL class=label for=user_zip_state>State:</LABEL></TD> > <TD><INPUT id=user_zip_state size=2 value=IL name=user.zip.state> > </TD></TR></DIV> > <TR> > <TD colSpan=2> > <DIV align=right><INPUT id=registerForm_0 type=submit value=Save> > </DIV></TD></TR></TBODY></TABLE></FORM> > <P align=center><FONT color=#808080 size=2>Copyright (c)2003-2007 The > DSMS > Software Foundation.</FONT></P> > <DIV>DEBUG: [zipDiv] Listening to zipEnteredTopic to > refresh</DIV></BODY></HTML> > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Scott [EMAIL PROTECTED]