When to encode html entities?
I'm trying to deal with some issues where JS goes nuts when data contains & ) /. These are popping up in user data for various reasons. Take the data "AT & T".
I want to get it back as this value in the POST, but the & kills JS and the form doesn't render.
I've done some experimenting with setting the control text with the &, but got this back in the data stream.
This gets back to the "TEXT" vs. "VALUE". If I load only the value portion of a tag
obj.setItemValue("AT & T"); this works, but the text value does not display.
Should I be doing ;
obj.setItemValue("AT & T");
obj.SetItemText("AT & T");
Lets say I have an array such for a combo box, does the same hold true?
I want to get it back as this value in the POST, but the & kills JS and the form doesn't render.
I've done some experimenting with setting the control text with the &, but got this back in the data stream.
This gets back to the "TEXT" vs. "VALUE". If I load only the value portion of a tag
obj.setItemValue("AT & T"); this works, but the text value does not display.
Should I be doing ;
obj.setItemValue("AT & T");
obj.SetItemText("AT & T");
Lets say I have an array such for a combo box, does the same hold true?
Myshka
November 18,