The moral of this story watch out for quotation marks when transferring your css code from html to external style sheet. I checked my recently made website template for cross browser compatibility and everything was fine. So I made an external style sheet and then starting making the web pages that I needed. And felt like everything was fine, and that’s what i thought for a week, until today. Just out of curiosity I checked for browser compatibility however when I viewed the website on Internet Explorer 7 I was extremely surprised, at the mess the web site looked like. I was actually embarrassed, I’ve coded many websites and a mistake like this are hard to make. Not only was the website not properly displaying but also my blog.
Once I noticed something was wrong, I quickly set out to fix it. I edited the CSS file and nothing would change, on the website itself. I was getting frustrated thinking, that the css file was not properly connected to the html file. So I decided to check for errors, and and could find nothing, I made sure that the css and html files were properly connected. .And knew that somehow internet explorer 8 and all the other browsers, ignored an error, that IE 7 didn’t.
Since the html, file seemed error free and w3 validator told me so, I moved on to the CSS validator. And found that I had a closing quotation mark, that I left from transferring css from html to my CSS style sheet. Once the closing quotation marks were taken out, the site displayed exactly as i wanted it to display. Having an external style sheet can and does save a lot of hours when modifying a website, but we need to be careful to check that there are no errors, when you transfer code from one source to another.
