Welcome to WebmasterWorld Guest from 54.159.30.26

Forum Moderators: incrediBILL

Message Too Old, No Replies

' for apostrophe

works in Firefox but not in IE

     
1:41 pm on Apr 18, 2006 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:Feb 25, 2003
posts:2528
votes: 0


I've tried using the coding ' instead of the actual ' but in IE it reads "it was the monkey's food" whereas in Firefox it shows fine as "it was the monkey's food".

What's the problem?

1:47 pm on Apr 18, 2006 (gmt 0)

Preferred Member

10+ Year Member

joined:June 25, 2002
posts:466
votes: 0


My understanding is that &apos is not valid HTML, so IE is actually behaving correctly. You can use &#39 instead.
4:06 pm on Apr 18, 2006 (gmt 0)

Preferred Member

10+ Year Member

joined:Aug 2, 2004
posts:551
votes: 0


Or you can escape it depending on the language you are using by using a "\" or another "'" in front of it.
4:08 pm on Apr 18, 2006 (gmt 0)

Senior Member from CA 

WebmasterWorld Senior Member encyclo is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Aug 31, 2003
posts:9074
votes: 6


'
exists in XML but it never made it into the slightly earlier HTML 4.01 list of character entities. The numeric entity will work, or just use the character directly.