Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 7 of 7
  1. #1
    New Coder
    Join Date
    May 2007
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Another annoying Firefox/IE discrepancy

    I've just finished the main template for my little web project, all using CSS, but I have a few pixels of difference when I view it in IE. I'd say there was around 2 or 3 pixels of vertical space presented in FF that are not there in IE. Those few pixles make all the different unfortunately as I am trying to match up diagonal stripes!

    I've uploaded my site to:
    http://download.yousendit.com/22B37B1912846BDC

    I have looked around the net for various solutions but none are really relevent to my situation. I have tried a few hacks but none of them have worked. Any suggestions would be welcome. I have to hand this in for an assignment on Friday! Very last minute of me, I know.

    Here's my CSS:

    Code:
    @charset "utf-8";
    .background {
    	background-image: url(Files/background_tile.gif);
    	background-position: center;
    	background-repeat: repeat-y;
    	background-color: #333333;
    }
    .logoposition {
    	margin-top: -300px;
    	margin-left: -149px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    }
    .redeembutpos {
    	margin-top: -115px;
    	margin-left: -180px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    	z-index: 1;
    	border: 0;
    }
    .aboutusbutpos {
    	margin-top: -115px;
    	margin-left: -91px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    	z-index: 2;
    }
    .helpbutpos {
    	margin-top: -115px;
    	margin-left: -2px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    	z-index: 3;
    }
    .logoutbutpos {
    	margin-top: -115px;
    	margin-left: 87px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    	z-index: 4;	
    }
    .blackboxpos {
    	margin-top: -54px;
    	margin-left: -242px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    }
    .legalboxpos {
    	margin-top: 218px;
    	margin-left: -180px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    }
    .legaltextpos {
    	margin-top: 230px;
    	margin-left: -92px;
    	position: absolute;
    	left: 50%;
    	top: 50%;
    	font-family: Arial, Helvetica, sans-serif;
    	font-size: 10px;
    	font-style: normal;
    	font-weight: normal;
    	font-variant: normal;
    	text-transform: lowercase;
    	color: #FFFFFF;
    }

  • #2
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    What is up with all of the absolute positioning? Also it would be easier if you could upload your site to an actual webhost rather than having us try to download your site and rebuild it.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #3
    Senior Coder jcdevelopment's Avatar
    Join Date
    Oct 2007
    Location
    Cowboy Nation
    Posts
    2,182
    Thanks
    174
    Thanked 257 Times in 257 Posts
    a quick easy fix possibly, do you have

    Code:
    * {
    margin:0px;
    padding:0px;
    }
    in your code?

  • #4
    New Coder
    Join Date
    May 2007
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by _Aerospace_Eng_ View Post
    What is up with all of the absolute positioning? Also it would be easier if you could upload your site to an actual webhost rather than having us try to download your site and rebuild it.
    The absolute positioning is the best way I've found to center elements on a page both vertically and horizontally - in my limited experience.

    I'm having trouble with my web host at the moment, that's the only reason I didn't give you a direct link.

    I tried the padding and margin tip suggested by jcdevelopment, but that did no good.

    Just to clarify, the problem seems to be with IE7 specifically. I just tried the site in IE6 and it displays fine.


  • #5
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,642
    Thanks
    0
    Thanked 649 Times in 639 Posts
    Using absolute positioning to center something is doing it the hard way.

    See http://www.felgall.com/cshow03.htm for the easiest way to center the content.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.

  • #6
    New Coder
    Join Date
    May 2007
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by felgall View Post
    Using absolute positioning to center something is doing it the hard way.

    See http://www.felgall.com/cshow03.htm for the easiest way to center the content.
    I'll use that next time, thanks for your help

  • #7
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,748
    Thanks
    22
    Thanked 1,838 Times in 1,822 Posts
    Hello GOAT2G,
    I'm not seeing anything wrong in IE7 compared to FF, in spite of what the validator says:Failed validation, 209 Errors

    Maybe you could be more specific with what's wrong?
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •