Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

coldfusion variable

Status
Not open for further replies.

vista

Programmer
Joined
Jul 4, 2000
Messages
9
Location
IN
<br>Can i pass a coldfusion variable to a javascript function?
 
I would think you'd be able to... that is if the Javascript interpreter does its job after Cold Fusion's interpreter does his.&nbsp;&nbsp;Basically, you would use Cold Fusion to write out the Javascript code, inserting the value of the variable you watn to use inline in the Javascript, not unlike this:<br><br>&lt;CFOUTPUT&gt;<br>&lt;script language=&quot;JavaScript&quot;&gt;<br>&lt;!--<br>var tempvar = #Variables.TheColdFusionVariable#<br>//--&gt;<br>&lt;/script&gt;<br>&lt;/CFOUTPUT&gt;<br><br>-ZD
 
<br>Thanx&nbsp;&nbsp;a lot..ZD,&nbsp;&nbsp;I will try..and get back to ya on the same
 
zd's right,<br>&nbsp;I have successfully created dynamic javascripts with cold fusion.<br>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top