Groups | Blog | Home
all groups > inetserver asp components > november 2003 >

inetserver asp components : Passing variables from ASP to Javascript


Gung Ho
11/28/2003 2:20:24 PM
I am using ASP to open a text file on the server and I want to pass
variables to Javascript.

Any suggestions?

For example - I have a text file on the server defining a set of pictures.
I open the text file to retrieve the list of files. I want to pass the list
of files to the Javascript which will then display the data on the client
machine.



PL
11/28/2003 8:26:08 PM

Didn't you get an answer in another group ?

Exactly what do you mean ? If you want to send values
to a client side script you just print it out on the page:

<%
yourvalue = "somevalue"
%>
<script>
var yourjsvariable = "<%= yourvalue %>";
</script>

PL.

"Gung Ho" <mikeNOSPAM_d2@netlane.com> skrev i meddelandet news:p96dnYZTEc9nAlqiRVn-vg@golden.net...
[quoted text, click to view]

AddThis Social Bookmark Button