Avatar of Quack
Quack
Flag for United States of America asked on

I have a Cold Fusion reset button that's not working w/ javascript turned off

I need a reset button to work w/in a Cold Fusion form without javascript as it has be functional without js turned on. Does anyone have any ideas? links to options? examples?
ColdFusion LanguageHTML

Avatar of undefined
Last Comment
Quack

8/22/2022 - Mon
erikTsomik

try something like this

<cfif isDefined("FORM.Reset")>
    <cflocation url="#cgi.script_name#" addtoken="false">
</cfif>

 <input type="button" name="Reset" value="Reset">
Quack

ASKER
Thanks...I'll try that...another suggestion that's come to me but I'm positive on how to write the logic is below:

1. create a form for the reset button on the same file...create the logic to check the reset button is being selected.

2. post the form back to the same page and reset the form fields  to ""

Do you have any examples I could lean on for this?
Quack

ASKER
<cfif isDefined("FORM.Reset")> ... is the FORM the name of the cfm file?
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes
ASKER CERTIFIED SOLUTION
Quack

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
erikTsomik

try changing the button type to submit

<cfif isDefined("FORM.Reset")>
    <cflocation url="#cgi.script_name#" addtoken="false">
</cfif>

 <input type="submit" name="Reset" value="Reset">
Quack

ASKER
no solution solved the issue...still unresolved at this point...deferred until end of July