Hi Gang-
Because of a custom framework that I'm forced to use I have a UI that utilizes tabs using the cflayoutarea tags. A few of these cflayoutareas contain cfform calls and I'd like to get those forms to submit to an entirely different page, NOT inside of the tabbed area. I actually want the entire page to refresh and the new page to display just as if I was using a cfform call in a standard .cfm page; I do not want to use the asynchronous call that the cfajax widgets provide. I thought it was something along the lines of how frames behave, simply adding something like "target='new'" but I'm drawing a blank on the javscript equivalent (or a cfml code frag). Anyone have a quickie solution?
Thanks in advance,
Rich
Hi Ian-
Thanks for your reply. Actually, the AJAX controls are very helpful and we'd like to continue using them if possible, however, per the CF docs, when using a cfform inside of a cflayoutarea tag the expected behavior is the asynchronous form submission, which is ironically what I don't want. I was playing around with ColdFusion.Ajax.SubmitForm and ColdFusion.Navigate but never really got it correct, I was hoping that there was a simple tag attribute or something like that where I could avoid the javascript code.
I'll keep trying and report back if I find anything. Thanks again for your reply.
Rich
This worked for me...
CFForm does something strange to the form code on submit. Make the type of the submit to 'button' and add javascript to submit the form. I have included the fix below.
<cflayout type="border">
<cflayoutarea position="top" size="80" align="right">
<p>
<cfform name="logMeout" action="#CGI.script_name#" method="post" target="_top">
<cfinput type="button" name="logout" value="Logout" onClick="javascript:document.logMeout.submit()"/>
</cfform>
</p>
</cflayoutarea>
Dennis
North America
Europe, Middle East and Africa
Asia Pacific