Reputation: 1921
I am doing application with strut1.2. In UI, in html text box i am have provided value with single quote punctuation but stored in DB as ? mark. So how to handle the same.
Ex: ‘torana’ becomes ?torana?. Please advise me on the same.
Thanks
Upvotes: 0
Views: 2651
Reputation: 432
Before Inserting the text field value into the DB,Once check the textbox value using replaceAll method use like variable_name.replaceAll("\'","_sq_"); and then print that replaced string .If you entered ‘torana’ it need to change like _sq_torana_sq_ . Otherwise you are getting something else
Upvotes: 1