A Conversation for Website Developer's Forum

Entity rendering

Post 1

Frankie Roberto

Another day, another problem...

I have a content-management-system, which, similar to h2g2, allows you to edit markup in form > textboxes. There's a problem with entities though - if you put θ in the textbox, send the text, it will work fine. But if you re-edit the text, the script will fetch the text, but the browser then renders θ as a character rather than the entity reference. Is there any way to escape this?


Entity rendering

Post 2

Ion the Naysayer

If you send back &theta you should get what you want. Gotta make sure the ampersand is unescaped when you read it back in though... (I'm not sure if it will be or not).


Entity rendering

Post 3

Ion the Naysayer

Missed a semicolon... θ it should be.


Key: Complain about this post

Write an Entry

"The Hitchhiker's Guide to the Galaxy is a wholly remarkable book. It has been compiled and recompiled many times and under many different editorships. It contains contributions from countless numbers of travellers and researchers."

Write an entry
Read more