Then when I run I get this error unterminated string literal selectAndUpdate('EA13','GY','210/60R. That means my third value from the db got problem due to the slash right? How to overcome this?
im trying to read an xml file and put it into a textarea on my page. here is the code that returns the xml file as a string:
Document doc = new Document(); SAXBuilder saxBuilder = new SAXBuilder("org.apache.xerces.parsers.SAXParser"); XMLOutputter xmlOut = new XMLOutputter(Format.getPrettyFormat()); doc = saxBuilder.build(filesName); String xml = outputter.outputString(doc);
no when i try to pass this to a javascript as follows: function putXML(fileName){ var blah = '<%= xml %>' document.btraxtestForm.HighwayMessage.innerText=blah; }
it gives me a unterminated string literal error.
also, i will never know the contents of this xml file so i cant split up the string. has anyone any ideas how i will fix this?
I created a simple WYSIWYG for creating CSS based webpages. It works exactly as assumed in Safari and Chrome. However, in firefox, when you copy/paste more than one line of text, instead of formatting it as html, in puts in line breaks causing the array storing all of the data to break into multiple lines and causing an unterminated string literal.
1. suggest why it is behaving this way? 2. suggest a work around to allow it to work on FF?
I'm getting an error message come up in IE6 when somenone subscribes to my newsletter from my home page (either from the drop down hover box form or the left hand form) here .
After entering a name and email address I get:
A runtime error has occurred....do you wish to debug? Line 4 Error: Unterminated string constant
When I click NO I then get a second small windows popup which says:
A runtime error has occurred....do you wish to debug? Error: Expected ')'
I've looked at lines 4 and 43 of my thanks.php page (the page subscribers get when they fill out the form but before they double optin via the email) and I can't find anything wrong. I guess the first message expects a semicolon and the second obviously a closing bracket. Code:
I am facing a problem in javascript. strdata is a variable of javascript and following is an assignment(hmm a Huge one but unfortunately its not mine code, I am just trying to rectify it) to this varibale.. Now I am facing a run time error(Unterminated string constant).....
in IE only (tested version 7) if var myWord = "English" then it works fine but if var myWord = "Modifier Chau00EEnes" then I get "Unterminated string constant" error.
What fix would you suggest to keep div.innerHTML = "" format?
Hi, this is the first lines of a function. Although it runs, it still throws an "Unterminated string constant" error in the browser. It is all in one line, just wouldn't fit here.....
<p> Howdy <p> expressed as a literal string that is passed to the setTimeout() function might look like this: setTimeout("document.getElementById('first').innerHTML = '<p>' + 'HOWDY' + '</p>';", 2000);
I guess you can't just put quotes around an expression like this: "'<p> HOWDY </p>;" So tags have to be isolated, but it get confusing with expressions like this, which I am not sure how to express as a string:
I wish I could change the " in there to ' and then just wrap the whole thing in double " This is what I came up with but it did not work: setTimeout("document.getElementById('first').innerHTML = '<p>' + '<h2' + 'class='pos_left'' + '>' + '<img' + 'src='car1.jpg'' + 'name='slide'' + 'width='400'' + 'height='250'' + '/>' + '</h2>' + '</p>';", 4000);
I am trying to create 3 elements on the fly when a button is clicked. The button is the show an upload form for images. I am using uploadify (first time using it) and I have several different upload type/options for them so I am sending id's to differentiate between them. The problem I am having is when trying to create the script tag which in turn controls the input file type tag, and it is baffling me. Here's the code first:
I built my website using Stacey app, and have installed the Jquery booklet plugin, but its not working, I get Uncaught Reference Error: $ is not defined. It is the script below that is not Working....
Why does the the following javascript function not work? This is not valid HTML (that is the problem). This works when not passing any arguments to the function. I think I'm required to have all element attribute values in quotes for XHTML standards. I've tried placing my echo statement argument in double and single quotes, and they both do not work. What simple thing am I missing?
Below I declared a basic object literal with 2 methods. The "doSomething" method is call from the "useDoSomething" method but the call is only sucessful if I use the "this" keyword or qualify the call with "SomeObj".
I have the following code which attaches a function to events in x number of comboboxes (x will probably always = 4, but I do not want to hard-code this). I wish to pass the value of i to the function being attached as well as the value of tempData. In other words, I want the parameters in function to be the value, not a reference variable.
In the current example, I am using the hard-coded variable ci. This I want to be replaced by a literal created when the event handler is attached (the value of the loop variable i). Also, notice that I get the filter value in the event handler (assigned to the variable ct). I would like to replace this code with the value of tempData which would also be determined when the evenet is attached (it is the same value in this case, but it keeps the onChange event from having to do this each time it runs).