I’m a big believer in the check often mentality when it comes to programming. Unfortunately I was racing to get some work done and I made a mistake that hopefully other people will benefit from. I also wanted to let you know I do most of my testing in IE. If there is going to be an issue, I will normally see it first in that browser. Today it was “firefox” that seemed to have the issue. It turned out I was just sloppy. Take a look at this code:
<img src="\images\line-break.jpg" class="lineBreak" />
While you might think that looks ok, it turns out there are issues with that code. The two issues are only an issue in Firefox. The issue why that image will not display in Firefox is that FireFox does not like “\” for defining folder structure.
If you use this code everything will look fine across all browsers.
<img src="/images/line-break.jpg" class="lineBreak" />
I don’t know why I accidentally typed in “\” instead of a “/” but it’s nice to know what each browser is capable of.