Goafer Posted May 25, 2009 Share Posted May 25, 2009 Hi, It's been a while since I have done any web design, and i'm currently knocking up a fairly basic site for a friend with minimal php etc. Since it's been a while, i'm trying hard to be quite clean with the coding and am taking care to use entity names where appropriate i.e. & instead of &. I'm really just wondering why ' doesn't work in IE, and as such, is it better to use ' or '. What is the difference in terms of compatibility etc? any knowledge greatly appreciated. Many Thanks, Chip(Goafer) Quote Link to comment https://forums.phpfreaks.com/topic/159572-iso-entity-names-apostophes/ Share on other sites More sharing options...
gffg4574fghsDSGDGKJYM Posted May 25, 2009 Share Posted May 25, 2009 ' is a xml/xhtml entities only, html doesn't have a entities for apos If you are using html you don't need to make a entity of the '/apos isn't needed at all no mater what charset you are using since aposthrophe is in the first 0-127 character(ASCII), if you are using xml you must (i think it's a must for xhtml too but i'm not sure as i don't know every detail of it). If you are using it in a URL you must encode it for both html and xhtml with rawurlencode() http://www.php.net/manual/en/function.rawurlencode.php What IE version are you using ? Did you use html or xhtml ? Quote Link to comment https://forums.phpfreaks.com/topic/159572-iso-entity-names-apostophes/#findComment-841878 Share on other sites More sharing options...
Goafer Posted May 26, 2009 Author Share Posted May 26, 2009 it's IE 7. I originally did use ' as I thought that was OK, however Google Chrome didn't recognise the ' and put in it's own little symbol for "what the hell is that" so I started using ' to overcome the situation before finding out that IE doesn't support ' So now i've got ' which seems to work in IE & Chrome & Firefox. I think it's just that Google have thrown things off a bit with the new browser. In answer to your question: yes, it's an XHTML document using standard charset iso-8859-1 Quote Link to comment https://forums.phpfreaks.com/topic/159572-iso-entity-names-apostophes/#findComment-842248 Share on other sites More sharing options...
DarkSuperHero Posted May 26, 2009 Share Posted May 26, 2009 Goafer check out the sticky post in this forum on HTML vs XHTML seems like IE doesnt serve up xHTML...and will always render it as HTML.....just some food for though :-) Quote Link to comment https://forums.phpfreaks.com/topic/159572-iso-entity-names-apostophes/#findComment-842287 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.