I am getting data from database that has single quotes in it. There are no problems in getting that, I get variable with single quotes in it
ex:
var title="vicky's blog";
Now the problem is I am not able to append this variable as title for anchor tag.
I have tried using escape, unescape, replacing with regex and all that. I think i am missing out something, please help.
http://jsfiddle.net/vigneshvdm/mtXSZ/
Please refer to this jsfiddle. Inspect the anchor tag there its not having the full variable as title.
I also tried solutions provided in