written site containing CSS background images and absolute and relative positioning.
Works fine in IE, however in Firefox, some of my background images are not displayed and my text positioning and block sizing has been completely ignored so that the page looks terrible.
What's going on here?Need a link to the site to really find out the "problem"unfortunately its still on localhost so can't help there.
However I have figured out the image problem. The image appeared in firefox when I changed positioning of the image within the element from right,top to center,center. IE was unaffected.
For the positioning problem I am creating a table structure using divs and spans. A div is defined for each line and each element within the line is a span. Each element uses a class with position: relative, top and left as 0, but with specific height and width values. It is the height and width values that are ignored such that each element is automatically sized to just contain the text between the <span></span> tag pair.could you post a copy of your stylesheet and html thenNo need. Should have just read my CSS textbook. According to it, height and width styles are only applicable to block level tags. a span is an inline tag, not a block level one. IE lets you get away with that. Firefox doesn't. Looks like I will have to use absolute positioning or change all my spans to divs.
Thanks for your attempt to help Bathurst.no that was wrong too. spans are ok but firefox just doesn't like inline styles so I've had to position all my spans absolutely within classes, one unique class for each element. Surely there's got to be an easier way.
As an aside, I'm new here having just set up my company. I notice there's a lot of anti-IE sentiment here as if everyone is used to developing with other browsers and then reluctantly having to make things work in IE. Why? Nearly all users will go to a site with IE so doesn't the opposite approach make more sense?The problem is that IE does the poorest job of all the leading browsers of conforming to the w3.org CSS standards. If you can design a page that validates with the w3.org HTML validator (<!-- m --><a class="postlink" href="http://validator.w3.org/">http://validator.w3.org/</a><!-- m -->) and CSS validator (<!-- m --><a class="postlink" href="http://jigsaw.w3.org/css-validator/">http://jigsaw.w3.org/css-validator/</a><!-- m -->), and it looks the way you want it to in Firefox, for example; then there's a good chance it will look right in Opera and Safari. There is also a good chance it will look OK in IE, too, but there is also a chance you'll need to do some tweaking to get it right in IE.
So by designing to a more standards-compliant browser and getting it right there, you start out with your page being done the "right" way, and then you can adjust as necessary to get it to work in IE. Besides, I think most of us are so tired of IE still being behind the times as far as standards compliance goes, that we design with another browser out of spite.
PS: If you haven't already, I suggest running your problematic page through the above validators before assuming this browser or that browser is doing something wrong. If your markup is wrong, then the browsers have to either "guess" what you meant, or just ignore it. In either case, it's not their fault if they "guess" differently.Thx NogDog
Works fine in IE, however in Firefox, some of my background images are not displayed and my text positioning and block sizing has been completely ignored so that the page looks terrible.
What's going on here?Need a link to the site to really find out the "problem"unfortunately its still on localhost so can't help there.
However I have figured out the image problem. The image appeared in firefox when I changed positioning of the image within the element from right,top to center,center. IE was unaffected.
For the positioning problem I am creating a table structure using divs and spans. A div is defined for each line and each element within the line is a span. Each element uses a class with position: relative, top and left as 0, but with specific height and width values. It is the height and width values that are ignored such that each element is automatically sized to just contain the text between the <span></span> tag pair.could you post a copy of your stylesheet and html thenNo need. Should have just read my CSS textbook. According to it, height and width styles are only applicable to block level tags. a span is an inline tag, not a block level one. IE lets you get away with that. Firefox doesn't. Looks like I will have to use absolute positioning or change all my spans to divs.
Thanks for your attempt to help Bathurst.no that was wrong too. spans are ok but firefox just doesn't like inline styles so I've had to position all my spans absolutely within classes, one unique class for each element. Surely there's got to be an easier way.
As an aside, I'm new here having just set up my company. I notice there's a lot of anti-IE sentiment here as if everyone is used to developing with other browsers and then reluctantly having to make things work in IE. Why? Nearly all users will go to a site with IE so doesn't the opposite approach make more sense?The problem is that IE does the poorest job of all the leading browsers of conforming to the w3.org CSS standards. If you can design a page that validates with the w3.org HTML validator (<!-- m --><a class="postlink" href="http://validator.w3.org/">http://validator.w3.org/</a><!-- m -->) and CSS validator (<!-- m --><a class="postlink" href="http://jigsaw.w3.org/css-validator/">http://jigsaw.w3.org/css-validator/</a><!-- m -->), and it looks the way you want it to in Firefox, for example; then there's a good chance it will look right in Opera and Safari. There is also a good chance it will look OK in IE, too, but there is also a chance you'll need to do some tweaking to get it right in IE.
So by designing to a more standards-compliant browser and getting it right there, you start out with your page being done the "right" way, and then you can adjust as necessary to get it to work in IE. Besides, I think most of us are so tired of IE still being behind the times as far as standards compliance goes, that we design with another browser out of spite.
PS: If you haven't already, I suggest running your problematic page through the above validators before assuming this browser or that browser is doing something wrong. If your markup is wrong, then the browsers have to either "guess" what you meant, or just ignore it. In either case, it's not their fault if they "guess" differently.Thx NogDog