[thelist] Javascript Variables to Cold Fusion Variables

Mike Stanley mikes at ablecommerce.com
Tue Jul 17 12:13:26 CDT 2001


You could try something like this:

<cfquery datasource="aDatasource" name="myQ">
SELECT userName
FROM Users
WHERE userID = '#cookie.userID#'
</cfquery>
<cfoutput>
<script language = "javascript">
alert('Hi there, #myQ.userName#');
</script>
</cfoutput>


At 12:06 PM 7/17/2001 -0500, you wrote:

>Is there a nice way to transfer javascript variables to coldfusion variables
>on the same page.
>
>I have thought it over and it seems like it might be imposible since the
>cold fusion is executed on the server before the javascript is executed by
>the browser.  Is this correct?
>
>Thanks,
>Josh
>
>
>_________________________________________________________
>Do You Yahoo!?
>Get your free @yahoo.com address at http://mail.yahoo.com
>
>
>---------------------------------------
>For unsubscribe and other options, including
>the Tip Harvester and archive of TheList go to:
>http://lists.evolt.org Workers of the Web, evolt !





More information about the thelist mailing list