[Zope] The proper usage of Sequence-item

jesse jesse@mail.multimediacollective.com
Tue, 18 Jul 2000 15:53:29 -0400


I'm improving on Smarter forms so that instead of having to hard code every field into the code that checks for errors, it automaticly reads the dictionary that is in REQUEST and checks every key in it.  I'm trying to work with this...

<dtml-call "REQUEST.set('finished','true')">
	
        <dtml-in "REQUEST.keys()">   
<dtml-comment> starting the loop </dtml-comment>
        <dtml-if "_[sequence-key].value('')">
<dtml-comment> I'm saying that if the current key is empty, display this. </dtml-comment>
		<li>Please fill in your <dtml-var "_['sequence-key']"> below
		<dtml-call "REQUEST.set('finished','false')">
	</dtml-if>
        </dtml-in>

	<dtml-if "REQUEST.get('finished')=='true'">
		<p>You're done! Thanks for your input <dtml-var fname>.</p>
		<p>You could put a link to somewhere else on your site here...</p>
	<dtml-else>
		<p>
		Please correct this and click the <i>Next</i> button to complete
		the form.
		</p>
		<dtml-var expr="mainform_include()">
	</dtml-if>


any input would be helpful.