Hi all, I am working in a struts application. I am getting two peculiar problems with java script in jsp. PROBLEM1: When ever I enter "\" in the text box I am getting un terminated string constant error. Please find the code snippet which I am using in jsp' This is the line of code that causes the issue. document.getElementById("text"+i).value = "<%=existingAnswer3%>"; When I view the source it looks like this document.getElementById("text"+i).value = "\"; ======================================================================== ============================= There is another line of code that causes the same above issue. When I view the source it looks like this ch4 ="\"; ======================================================================== ============================== PROBLEM2: If I enter "" in text box I am getting the following error. Error: Expected ';' This is the line of code that causes the issue. document.getElementById("text"+i).value = "<%=existingAnswer3%>"; When I view the source it looks like this document.getElementById("text"+i).value = """"; Please help me out what can be done to fix this. ======================================================================== ============================= There is another line of code that causes the same above issue. When I view the source it looks like this ch4 =""""; Regards, I.HariKrishna | Software Engineer | Franklin Templeton International Services (India) Pvt. Ltd. | Franklin Templeton Centre,1st Floor, No.7,Third Cross Street, Kasturba Nagar, Adyar, Chennai 600020 | Tel: +91 44 24407000 | Extn: 17123 | Fax: +91 44 24453661 | Mobile: +91 9884528587 | www.franklintempleton.com Notice: All email and instant messages (including attachments) sent to or from Franklin Templeton Investments (FTI) personnel may be retained, monitored and/or reviewed by FTI and its agents, or authorized law enforcement personnel, without further notice or consent.