Yeah, but why bother when I can just do:
<cfwddx action="CFML2JS" input="#yourquery#"
toplevelvariable="theJSArray">
----- Original Message -----
From: Douglas Brown <[EMAIL PROTECTED]>
Date: Thursday, March 14, 2002 2:20 pm
Subject: Re: Java Script Array Question
> You can do this.
>
>
> <script language="javascript">
> images = Array New(){
> <cfoutput query="yourQuery">
> images[#yourQuery.currentrow#] = #yourQuery.image#;
> <cfoutput>
> }
> </script>
>
>
>
>
>
>
>
> "Success is a journey, not a destination!!"
>
>
>
> Doug Brown
> ----- Original Message -----
> From: <[EMAIL PROTECTED]>
> To: "CF-Talk" <[EMAIL PROTECTED]>
> Sent: Thursday, March 14, 2002 1:08 PM
> Subject: Re: Java Script Array Question
>
>
> > The easiest way to do this is to use WDDX. It will create an
> array for
> > you in JS straight from your CF query.
> >
> > Take a look in the CF Studio help, it's very straightforward.
> >
> > ----- Original Message -----
> > From: Double Down <[EMAIL PROTECTED]>
> > Date: Thursday, March 14, 2002 1:47 pm
> > Subject: Java Script Array Question
> >
> > > I am pulling the names of five images from my db and I need to
> > > populatethe array inside the javascript with the path to and
> the
> > > name of the
> > > image.
> > >
> > >
> > > Pic[0] = '1.jpg'
> > > Pic[1] = '2.jpg'
> > > Pic[2] = '3.jpg'
> > > Pic[3] = '4.jpg'
> > > Pic[4] = '5.jpg'
> > >
> > > TIA
> > >
> > > HB
> > >
> > >
> > >
> > >
> >
>
______________________________________________________________________
Dedicated Windows 2000 Server
PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
Instant Activation � $99/Month � Free Setup
http://www.pennyhost.com/redirect.cfm?adcode=coldfusiona
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists