This should have been fixed in 5.0 as well. Anyway, yes, it's also fixed in MX.
======================================================================= Raymond Camden, ColdFusion Jedi Master for Macromedia Email : [EMAIL PROTECTED] Yahoo IM : morpheus "My ally is the Force, and a powerful ally it is." - Yoda > -----Original Message----- > From: Ben Johnson [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, July 03, 2002 2:04 PM > To: CF-Talk > Subject: JS WDDX Problem - Is it fixed? > > > I have used the WDDX tag extensively in the past to pass variables to > javascript but I always had a problem when passing structures that use > integers as their keys. > > For example: > > <cfset myStruct = StructNew()> > <cfset myStruct[3] = "test"> > <cfset myStruct[8] = "hello"> > > <script> > <cfwddx action="cfml2js" input="#myStruct#" > toplevelvariable="mystruct"> > </script> > > This ends up erroring because when you look at the output, it shows: > > <script> > var mystruct = new Object(); > mystruct.3 = 'test'; > mystruct.8 = 'hello'; > </script> > > It would all work great if it used brackets instead of dot notation: > > <script> > var mystruct = new Object(); > mystruct['3'] = 'test'; > mystruct['8'] = 'hello'; > </script> > > > My question is whether Macromedia realizes the bug and if it has been > corrected with CFMX. Anybody know? > > > > > Ben Johnson > > ______________________________________________________________________ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm 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

