JSStringFormat() not escaping everything..

Posted on 2007-09-27
Medium Priority
Last Modified: 2013-12-24
I am using the following line in my code to populate a DIV on my page..

 obj.innerHTML = '#JSStringFormat(variables.content)#'

The variable "variables.content"  holds some coldfusion generated HTML
This has always worked in the past, until I put <CFCHART>  in the .cfm file.  The chart format is FLASH.

Now I get an error on the line...
 obj.innerHTML = '#JSStringFormat(variables.content)#'
that says "Unterminated String"    

JSStringFormat() has always handled escaping the characters for me, until including this flash (it doesn't fail for CFCHART using a graphic format).

Does anyone have an experience with this?  
Is there some other way to 'escape' the code?  Why does it fail with flash ?
Question by:gdemaria

Accepted Solution

Andrew Maurer earned 1500 total points
ID: 19984597

 obj.innerHTML = "JSStringFormat('#variables.content#')"


 obj.innerHTML = JSStringFormat('#variables.content#')
LVL 39

Author Closing Comment

ID: 31407942
They didn't work, but I appreciate the effort.  Sorry to have forgotten about the question.  Turns out we switched to another method for other reasons so it became a non-issue.  

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
Introduction This article explores the design of a cache system that can improve the performance of a web site or web application.  The assumption is that the web site has many more “read” operations than “write” operations (this is commonly the ca…
Are you ready to place your question in front of subject-matter experts for more timely responses? With the release of Priority Question, Premium Members, Team Accounts and Qualified Experts can now identify the emergent level of their issue, signal…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Suggested Courses
Course of the Month14 days, 8 hours left to enroll

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question