« Return to Thread: JavaScript setAttribute function generates attributes without quotes
First, thanks for the reply.Secondly, <cfxml> is a tag used to accept inline XML inside Coldfusion. If you are using the ## mechanism to take some variable and have it rendered as XML inside the <cfxml> tag then you probably need to use the preserveSingleQuotes method to ensure that single quotes created in another XML string representation are faithfully maintained in Coldfusion.It's not XML yet at this stage, it is HTML. I do believe JavaScript is adding the double quotes around the value once I add them manually, so preserveSingleQuotes won't do the trick.Working with DOM is exactly what I am doing, so you reckon its normal it doesn't generate quotes around the value simply because it is not XML, ok.I am parsing the HTML now anyway to get at the values I need in CF, I just thought it would be easy to convert the document to XML so I could easily address the attributes in CF without the need for parsing etc..Kind regards,Taco Fleur - Chief Executive Officer
Pacific Fox http://www.pacificfox.com.au an industry leader with commercial IT experience since 1994 …
Web Design and Development SMS Solutions, including developer API Domain Registration, .COM for as low as fifteen dollars a year, .COM.AU for fifty dollars two years! BlackBerry® Business Solutions www.OzBlackBerry.com We endorse PayPal, accept payments online now! Seamless Merchant integration
From: bounce-cfaussie-21343@... [mailto: bounce-cfaussie-21343@...] On Behalf Of Gary Menzel
Sent: Thursday, 29 December 2005 5:50 PM
To: CFAussie Mailing List
Subject: [cfaussie] Re: JavaScript setAttribute function generates attributes without quotes
b‹šç.®·§¶\¬¹»®&ÞvÚ}«¬²'š²Öœ¡ù^ººZr'âqú1r‰"¢éì¹»®&Þ±éÝi¹ZžG¦j)m¢Wš½çjë,‰íµßΖ+-±Öžš‰Ü¢f®ë,‰ãrº&yØš ëÞ–Š^®Èm¶Ÿÿ–+-±Öžš‰Ü¢f®Firstly, the JavaScript setAttribute doesn't set quotes because it doesn't generate XML. It simply creates the attribute as part of the elements DOM structure. If you aren't getting quotes when you generate XML it will be related to the method that is generating the XML (not the setAttribute method).Secondly, <cfxml> is a tag used to accept inline XML inside Coldfusion. If you are using the ## mechanism to take some variable and have it rendered as XML inside the <cfxml> tag then you probably need to use the preserveSingleQuotes method to ensure that single quotes created in another XML string representation are faithfully maintained in Coldfusion.
On 12/23/05, Taco Fleur - Pacific Fox <taco.fleur@...> wrote:The JavaScript setAttribute function generates attributes without quotes, I am using <cfxml> to turn the document constructed in javascript into an XML doc, obviously without the attributes properly quoted it errors. Anyone any idea how to get JavaScript to create the attributes with quotes?Kind regards,Taco Fleur - Chief Executive Officer
Pacific Fox http://www.pacificfox.com.au an industry leader with commercial IT experience since 1994 …
Web Design and Development SMS Solutions, including developer API Domain Registration, .COM for as low as fifteen dollars a year, .COM.AU for fifty dollars two years! BlackBerry® Business Solutions www.OzBlackBerry.com We endorse PayPal, accept payments online now! Seamless Merchant integration---
You are currently subscribed to cfaussie as: gmenzel@...
To unsubscribe send a blank email to leave-cfaussie-7952D@... Aussie Macromedia Developers: http://lists.daemon.com.au/---
You are currently subscribed to cfaussie as: gmenzel@...
To unsubscribe send a blank email to leave-cfaussie-7952D@... Aussie Macromedia Developers: http://lists.daemon.com.au/
« Return to Thread: JavaScript setAttribute function generates attributes without quotes
| Free embeddable forum powered by Nabble | Forum Help |