sandy1028 Posted April 28, 2009 Share Posted April 28, 2009 Hi, Suppose two values are appended with ; i.e for example This is a function function append(){ filter('alerts', document.getElementById('view_alert').value + ";" + document.getElementById('id').value); } and if document.getElementById('id').value has a "," in it. Does it ignores the string after ",". <form onSubmit="append(); return false;"> the value after submitting the form the document.getElementById('id').value doesnot contain string after comma. Quote Link to comment Share on other sites More sharing options...
Axeia Posted April 28, 2009 Share Posted April 28, 2009 and if document.getElementById('id').value has a "," in it. Does it ignores the string after ",". Is that the question? No, javascript doesn't magically start ignoring the rest of a string once it finds a comma. Your alert should show all of the text in both view_alert and id with a ';' in the middle. And please use [code] [/code] tags to post code. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.