Buddy Bradley
June 21st, 2001, 12:01
I am trying to populate a javascript variable with a string from a database using ASP. The string stretches over a number of lines:
this is line one
this is line two
This means that when the asp writes the string into the variable, it writes:
var my_variable = "this is line one
this is line two
;"
This is causing an "unterminated string constant error" (cos the javascript line spills onto three lines in the above example). Can anyone tell me how to get round this?
this is line one
this is line two
This means that when the asp writes the string into the variable, it writes:
var my_variable = "this is line one
this is line two
;"
This is causing an "unterminated string constant error" (cos the javascript line spills onto three lines in the above example). Can anyone tell me how to get round this?