Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: Center a website problem  (Read 10563 times)

0 Members and 1 Guest are viewing this topic.

TechFixOrg



    Rookie
    • Yes
    • TechFix.org
  • Certifications: List
  • Experience: Guru
  • OS: Windows 7
Re: Center a website problem
« Reply #15 on: November 20, 2010, 01:29:43 AM »

TechFixOrg



    Rookie
    • Yes
    • TechFix.org
  • Certifications: List
  • Experience: Guru
  • OS: Windows 7
Re: Center a website problem
« Reply #16 on: November 20, 2010, 02:19:50 AM »
Use css instead of html to center it.

example:
Code: [Select]
.center
{
   margin-left:auto;
   margin-right:auto;
   width:75%;
}

TechFixOrg



    Rookie
    • Yes
    • TechFix.org
  • Certifications: List
  • Experience: Guru
  • OS: Windows 7
Re: Center a website problem
« Reply #17 on: November 20, 2010, 02:22:52 AM »
also... you have this:
Code: [Select]
<div id="masthead">
  <div align="center"><img src="header.jpg" width="822" height="172"></div>
</div>

you left out a / in your image tag, it should be:
Code: [Select]
<div id="masthead">
  <div align="center"><img src="header.jpg" width="822" height="172" /></div>
</div>


Typhoon

  • Guest
Re: Center a website problem
« Reply #18 on: November 20, 2010, 01:56:48 PM »
ok ill try that thanks

jim345

  • Guest
Re: Center a website problem
« Reply #19 on: November 22, 2010, 05:21:47 AM »
I am having the same  problem. It is annoying wit IE.

Quantos



    Guru
  • Veni, Vidi, Vici
  • Thanked: 170
    • Yes
    • Yes
  • Computer: Specs
  • Experience: Guru
  • OS: Linux variant
Re: Center a website problem
« Reply #20 on: November 23, 2010, 12:25:11 AM »
I am having the same  problem. It is annoying wit IE.
Start a new thread, we will assist you there.
Evil is an exact science.

TechFixOrg



    Rookie
    • Yes
    • TechFix.org
  • Certifications: List
  • Experience: Guru
  • OS: Windows 7
Re: Center a website problem
« Reply #21 on: November 23, 2010, 07:05:17 AM »
Try This...

Code: [Select]
<div id="masthead">
    <div style="text-align:-moz-center; text-align:center; ">
        <img src="header.jpg" width="822" height="172" />
    </div>
</div>

Typhoon

  • Guest
Re: Center a website problem
« Reply #22 on: December 02, 2010, 11:34:23 AM »
Try This...

Code: [Select]
<div id="masthead">
    <div style="text-align:-moz-center; text-align:center; ">
        <img src="header.jpg" width="822" height="172" />
    </div>
</div>


No that doesn'r work

shpgrl



    Starter

    • Experience: Beginner
    • OS: Unknown
    Re: Center a website problem
    « Reply #23 on: December 10, 2010, 06:38:06 PM »

    What happened to just using
    <center > before your body and
    </center > after

    or one right after your opening head tag and one right before the ending head tag, depending on how your page is set up.

    Has always worked for me.

     

    BC_Programmer


      Mastermind
    • Typing is no substitute for thinking.
    • Thanked: 1140
      • Yes
      • Yes
      • BC-Programming.com
    • Certifications: List
    • Computer: Specs
    • Experience: Beginner
    • OS: Windows 11
    Re: Center a website problem
    « Reply #24 on: December 10, 2010, 06:40:55 PM »
    What happened to just using
    <center > before your body and
    </center > after

    or one right after your opening head tag and one right before the ending head tag, depending on how your page is set up.

    Has always worked for me.


    yeah that was a great solution,

    in 1996.
    I was trying to dereference Null Pointers before it was cool.

    shpgrl



      Starter

      • Experience: Beginner
      • OS: Unknown
      Re: Center a website problem
      « Reply #25 on: December 10, 2010, 06:49:58 PM »

      yeah that was a great solution,

      in 1996.


      So you're saying that doesn't work anymore?

      Worked for me as of....um....last week?

      BC_Programmer


        Mastermind
      • Typing is no substitute for thinking.
      • Thanked: 1140
        • Yes
        • Yes
        • BC-Programming.com
      • Certifications: List
      • Computer: Specs
      • Experience: Beginner
      • OS: Windows 11
      Re: Center a website problem
      « Reply #26 on: December 10, 2010, 06:52:01 PM »
      So you're saying that doesn't work anymore?
      Never said that.

      But you know what else works? Netscape navigator 4.
      I was trying to dereference Null Pointers before it was cool.

      kpac

      • Web moderator
      • Moderator


      • Hacker

      • kpac®
      • Thanked: 184
        • Yes
        • Yes
        • Yes
      • Certifications: List
      • Computer: Specs
      • Experience: Expert
      • OS: Windows 7
      Re: Center a website problem
      « Reply #27 on: December 12, 2010, 02:59:35 PM »