INPUT tag is part of a FORM set.
If you do not want to use a FORM
then yes you can use Javascript 
but you will need to PASS the textvar 
variable to your action page.


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, June 12, 2001 10:17 AM
To: CF-Talk
Subject: RE: <CFFILE & <TEXTAREA>



Thanks works great.

Would it be possible to have the <INPUT> tag do the submit to the template 
form rather than the <FORM>
Would I have to use javascript?

At 09:36 AM 6/12/01 -0400, you wrote:
>reason is you need to pass the TEXTAREA information
>as a form element. You are only telling it to write
>the SESSION information. You are not saying anything
>regarding the NEW Information.
>
>So your first page:
>
><form action="action-write.cfm" method=post>
><cffile action="READ"
>file="#URLDecode(application.dirpath)##URLDecode(datafile)#"
>variable="textvar">
><textarea cols="70" rows="25" name="textvar" id="textvar" wrap="off">
><cfoutput>#HTMLEditFormat(textvar)#</cfoutput>
><cfset session.writeoutput = #HTMLEditFormat(textvar)#>
></textarea>
><input type=submit value="[SAVE]">
>
>
>
>Action-write Page:
><cfset session.writeoutput = #session.writeoutput# & #form.textvar#>
><cffile action="WRITE" file="C:\output.txt" output="#session.writeoutput#"
>addnewline="Yes">
>
>
>
>-----Original Message-----
>From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
>Sent: Tuesday, June 12, 2001 9:26 AM
>To: CF-Talk
>Subject: Re: <CFFILE & <TEXTAREA>
>
>
>
>
>Hi,
>
>I'm having a problem trying to save any changes that I make to the file
>once it's opened in the <textarea> box.
>
>The file gets written out but not any additions?
>
>
><cffile action="READ"
>file="#URLDecode(application.dirpath)##URLDecode(datafile)#"
>variable="textvar">
><textarea cols="70" rows="25" name="textvar" id="textvar" wrap="off">
><cfoutput>#HTMLEditFormat(textvar)#</cfoutput>
><cfset session.writeoutput = #HTMLEditFormat(textvar)#>
></textarea>
>
>
>    <a href="action-write.cfm" class="midnavlinks">[SAVE]
>
>
>action-write.cfm file
>--------------------------
>
>
>
><cffile action="WRITE" file="C:\output.txt" output="#session.writeoutput#"
>addnewline="Yes">
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to