www.webdeveloper.com
Results 1 to 5 of 5

Thread: [RESOLVED] Two images separated by <br />

  1. #1
    Join Date
    Jun 2012
    Location
    FL, USA
    Posts
    48

    resolved [RESOLVED] Two images separated by <br />

    I want two images to render as touching DIRECTLY with no space using <br />.

    Firefox and all the other good browsers do it fine. I'm having trouble with IE.

    IE!! Gah.

    Anywho, I've tried:

    HTML Code:
    img {
    padding: 0px;
    margin: 0px;
    }
    in my IE stylesheet. Doesn't work.

    Thanks for help in advance

  2. #2
    Join Date
    Aug 2006
    Posts
    1,943
    Do you have a link to the site, so we can see the problem?

    Dave

  3. #3
    Join Date
    Jul 2012
    Posts
    22
    Sometimes i get weird about IE as well, all Chrome and Firefox work well but IE.

    You have to give some sample of code or give the link to the page, or we don't know how the symptom it is.

  4. #4
    Join Date
    May 2005
    Location
    Gold Coast (MS)
    Posts
    2,219
    Quote Originally Posted by captainscall View Post
    I want two images to render as touching DIRECTLY with no space using <br />.

    Firefox and all the other good browsers do it fine. I'm having trouble with IE.

    IE!! Gah.

    Anywho, I've tried:

    HTML Code:
    img {
    padding: 0px;
    margin: 0px;
    }
    in my IE stylesheet. Doesn't work.

    Thanks for help in advance
    I take it that using <br /> you want the images touching vertically without any space. A lot also depends on whether you have whitespace in your html file.

    Try putting this at the very beginning of your CSS:

    Code:
    * { margin: 0; padding: 0; border: 0; }
    Delete your
    Code:
    img {
    padding: 0px;
    margin: 0px;
    }
    in your CSS file.

    Or, you could use Meyer's Reset CSS.

    Would like to know how your HTML file is laid out and how much excessive whitespace is in it.

  5. #5
    Join Date
    Jun 2012
    Location
    FL, USA
    Posts
    48
    Hello all, thanks for the responses.

    I figure the error was occurring because the first image actually rendered from a 3rd party Javascript code which I have no control over, It's just a page view counter script.

    e.g.
    Code:
    <script type="javascript" src="somefile.js?img=9>blahblahblahblah</script>
    <br />
    <img blah blah />
    No white space.
    I don't care enough to try the CSS fix.. I'm just getting rid of that tasteless page counter and using my own analytics..

    Thanks again.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles