Page 1 of 2 12 LastLast
Results 1 to 10 of 15
  1. #1
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Can't get logo div and horizontal menu div to touch

    Hi guys. I'm trying my hand at creating my own template. I'm using the Classic Green template as the basis for my changes. Just changing one thing at a time until it looks how I want it. Right now I've gotten stuck. For some reason there's a big space between the part where my logo goes, and where the horizontal menu for EZ Pages go. I don't want a gap there, but can't seem to find any CSS that might be causing it.

    You can see the page here: http://www.chuckwa.com/store/

    Right now there's a gap between the red bottom of my logo, and the black "border" around the EZ Pages navigation.


    However I want there to be no gap, like this:


    Any idea where that extra margin/padding/whatever is coming from and how to remove it? It shows up in both Mozilla and IE.

  2. #2
    Join Date
    Aug 2005
    Location
    Arizona
    Posts
    27,761
    Plugin Contributions
    9

    Default Re: Can't get logo div and horizontal menu div to touch

    Try adding a height to this that is highlighted in red to your stylesheet
    Code:
    #logoWrapper{
    	background-image: url(../images/header_background.gif);
    	background-repeat: repeat-x;
    	margin: 0px;
            height: 275px;
    	}
    Zen-Venom Get Bitten

  3. #3
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    That solved it, thanks!

    Any idea why the DIV was too big without it? I'm still learning CSS and still figuring out how it all works.

  4. #4
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    Whoops, I might have spoken too soon. Adding the height did not solve the issue at all in IE.

    In Mozilla, it looks good unless my browser window is open wider than the logo.gif, then I have a new problem:

    Last edited by Chuckwa; 28 Apr 2008 at 03:02 AM.

  5. #5
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    Right now, I'm thinking it has something to do with the <br> that acts as a float clear in the HTML. If I change the default font size in Header DIV, it changes the size of the gap.

    Anyone know which file I would need to edit to remove or modify that <BR> that gets inserted after the close of the logo DIV?

  6. #6
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    Ok, I have confirmed it is the
    Code:
    <br class="clearBoth" />
    that appears after the logo that is causing this problem.

    I created a work around using CSS, that appears to solve the problem in IE, and almost solves the problem in Mozilla (depending on resolution when page is rendered).

    I would rather edit the file that inserts the BR into the document, that should allow me to implement a 100% fix. Any idea which file to edit?

    header.php is not the right file. I most likely need the file that calls this file.

  7. #7
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    Ok. Problem solved.

    The file I need to edit is \common\tpl_header.php

    Once copying that to my custom template folder and editing it to comment out the clears, I've been able to get everything to display properly in Mozilla with no funny work arounds. One small work around to get everything 100% in IE, but even without that it works much better than before.

  8. #8
    Join Date
    Apr 2008
    Location
    Flint, Michigan
    Posts
    687
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    I may have missed this in an earliler thread. I am having the same problem with space between header & categories to match.

    When going to \common\tpl_header.php what edit did you do to it.

    Currently, mine looks like <br class="clearBoth" />

  9. #9
    Join Date
    Apr 2008
    Posts
    42
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    I removed that entirely.

  10. #10
    Join Date
    Mar 2008
    Location
    Cape Town & London (depends on the season)
    Posts
    2,975
    Plugin Contributions
    0

    Default Re: Can't get logo div and horizontal menu div to touch

    Careful which one you edit / remove.

    The one you're after is just ABOVE the:-
    <!--eof-branding display-->
    ... around lines 90 / 94

    HTML Code:
    <br class="clearBoth" />
    <!--eof-branding display-->
    ... and I don't usually DELETE lines - I rather comment them out, so later, if I need to restore stuff, I know where my edits are:-

    HTML Code:
    <!--WEBMASTER EDIT BEGIN<br class="clearBoth" />WEBMASTER EDIT END-->
    <!--eof-branding display-->

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 5
    Last Post: 28 Feb 2014, 12:30 PM
  2. v139h How to get div#NavEZpagesTop on same line as div#NavMain
    By idc1 in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 12 Mar 2013, 06:16 PM
  3. How to get rid of Breadcrumb Div?
    By john4803 in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 27 Sep 2010, 01:20 AM
  4. Div's adding random horizontal lines
    By TheHYPO in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 15 Mar 2008, 01:01 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR