Skip navigation
Currently Being Moderated

Need a little help with my header

Nov 30, 2012 11:51 AM

I'm having issues getting things to align and I just can't find the mistake.

 

I want my header and menu from the home page (Gsld.net/civic2/index.html) to be the same place on my project page (gsld.net/civic2/civic2.html). I've been trying for hours oflline since my last upload and I can't get it to work. I tried copyig code from the home page and  it doesn't help. The orange line and header is slightly lower on that page and the menu is higher. I can't find the error.

 

 

Please Help

 

thanks

 
Replies
  • Currently Being Moderated
    Nov 30, 2012 11:58 AM   in reply to webnewbie1284

    You have a set of <p></p> immediately after the container div on the one with the larger space. You should be able to remove those and fix it.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:00 PM   in reply to Jon Fritz II

    You also have some coding errors in that page. Your <title> is outside your <head> tags, that should be moved after the starting <head>

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:04 PM   in reply to webnewbie1284

    The ones I am pointing to on the Civic page should have nothing to do with your styles...

     

    <div id="apDiv2">Gary Steffy Lighting Design Inc.  | GSLD™</div>

    <div class="container">

    <p>& n b s p ;</p>

    <div class="header">

     

    to

     

     

    <div id="apDiv2">Gary Steffy Lighting Design Inc.  | GSLD™</div>

    <div class="container">

    <div class="header">

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:10 PM   in reply to webnewbie1284

    Sorry, I meant the Home page has the extra <p> n b s p ;</p> that should be deleted.

     

    I zigged when I should have zagged.

     

    So, yeah, if you want the space to grow, add them in so both pages have it.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:11 PM   in reply to webnewbie1284

    Both pages should have it to have the larger space.

     

    We seem to be typing over each other, no biggie.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:16 PM   in reply to webnewbie1284

    webnewbie1284 wrote:

     

    I want the Civic to look like the Home page, so I need to ad the NBSP, is that what you are saying? Is there a way to define nbsp height?, because when I add one to Civi it's much bigger line space, that the one in home.

     

    It's controlled by the actual <p> tag, not the non breaking space character.. Also, don't forget to fix your title location as I mentioned above, that has the potential to throw browsers out of wack pretty easily.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:29 PM   in reply to webnewbie1284

    Best advice, put all your styles into one external style sheet and link all your HTML pages to that CSS file.  This will keep your page styles consistent throughout so you'll have fewer problems like this in the future.

     

    Home page styles are not the same as Civic page styles.  Open the code and compare styles in #APDiv2.

     

     

     

    Nancy O.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 12:34 PM   in reply to webnewbie1284

    I was trying to compare your css, I figured the problem would likely be there.

     

    I ran into a bunch of errors.

     

    Run your page through this validator to fix the errors. You'll likely need to change some values once you fix them...

     

    http://jigsaw.w3.org/css-validator/

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 1:04 PM   in reply to webnewbie1284

    I believe the default used by most browsers is

     

    margin:1em 0px;

     

    Which gives 1em spacing to the top and bottom with 0px left and right.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 1:17 PM   in reply to webnewbie1284

    Different results caused by different styles. 

     

    Why don't you copy the home page (File > SaveAs > Civic.html) and begin again?

     

     

    Nancy O.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 1:35 PM   in reply to webnewbie1284

    The organization of your site is such that starting over will probably take less time and produce better results in the long run. 

     

    Don't postpone organizing your site's stylesheets either 'cuz this will come back to haunt you.

     

     

     

    Nancy O.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 1:40 PM   in reply to Nancy O.

    Nancy O. wrote:

     

    Don't postpone organizing your site's stylesheets either 'cuz this will come back to haunt you.

     

     

    Over and over and over...

     

    I remember the days before I started using a single external stylesheet for my site layout. I will never go back. It helps in a big way when all of your styles are in one place. You really start to notice the redundancy and are able to make much lighter code in the long run.

     

    Plus you only have one thing to change if you decide that you want to make your gold headers green at a later date, for example. Rather than scrolling through each page to find where the code is, you open your external file, change it once and you're done.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 1:48 PM   in reply to webnewbie1284

    File > New > Blank page > CSS.

     

    Copy & paste all your relevant CSS code into this new file and SaveAs GSStyles.css (or whatever name you wish).

     

    Link all your HTML pages to your new CSS file.

    See link below for details.

    http://alt-web.com/DEMOS/DW-Link-Stylesheet.shtml

     

     

    Nancy O.

     
    |
    Mark as:
  • Currently Being Moderated
    Nov 30, 2012 1:52 PM   in reply to Nancy O.

    One note to go with Nancy's suggestion and link is to make sure your new .css file has no html tags in it. Your <style> tags that surround your current css in your html file do not get transferred to the .css file.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points