WordPress.org

Ready to get started?Download WordPress

Forums

Logo In Portofolio Press (15 posts)

  1. milanoelectronics
    Member
    Posted 2 years ago #

    I have been trying to center a logo in my header file but have not been able to do so. http://www.milanoelectronics.co.ke
    Have tried several things according to the forums online but have not been able to sort this out.
    Will appreciate any help.

  2. gomeetpete
    Member
    Posted 2 years ago #

    Go into the theme css (under Appearance > Editor > style.css) and search for #logo.

    Then, take the following steps:
    1. Remove the line that says float: left;
    2. Add a new line that says margin: 0px auto;
    3. Add another new line that says width: 678px;

    You should end up with the following:

    #logo {
    margin: 0px auto;
    width: 678px;
    }

    Let me know if that works for you.

  3. milanoelectronics
    Member
    Posted 2 years ago #

    No luck. Tried doing as you said, but it does not help

  4. gomeetpete
    Member
    Posted 2 years ago #

    hmmm works for me when I preview the changes in my browser. Can you confirm that you edited the style.css file for the portfolio press theme?

    Since I'm unable to look at what you changed, please confirm that you entered the code exactly as above.

  5. milanoelectronics
    Member
    Posted 2 years ago #

    #logo {
    	margin: 0px auto;
    	width: 678px;
     }

    it looks like the above. doesn't seem to work.
    yes, the portofolio press theme.

  6. gomeetpete
    Member
    Posted 2 years ago #

    add a new line below width that says display: block;

  7. milanoelectronics
    Member
    Posted 2 years ago #

    No luck with that either :s

    Thanks for the help by the way

  8. gomeetpete
    Member
    Posted 2 years ago #

    it works for me in Google Chrome, Firefox, and Internet Explorer...it looks like you accidentally changed the width from 678px to 68px so now it's aligning to the far right.

  9. milanoelectronics
    Member
    Posted 2 years ago #

    Was just checking if it would make a difference. I set it back to 678 and now see that it works on Chrome. I still have the same problem with Internet Explorer. Any idea how/why it may be so ?

  10. gomeetpete
    Member
    Posted 2 years ago #

    It looks fine on IE7 & IE8, unfortunately I don't have vista or Windows 7 on the computer I'm on at the moment so I can't test it in IE9. Is that what version you're using?

  11. gomeetpete
    Member
    Posted 2 years ago #

    To answer "why"...Internet Explorer as a browser is horrible. =)

  12. milanoelectronics
    Member
    Posted 2 years ago #

    Haha !
    that is right. i am using the IE9. find it strange that it doesnt work.
    wonder if there is a solution to this.

  13. gomeetpete
    Member
    Posted 2 years ago #

    try adding a new line that says text-align: center;

  14. milanoelectronics
    Member
    Posted 2 years ago #

    that did not work for some reason.

  15. gomeetpete
    Member
    Posted 2 years ago #

    I wish I had my other computer with me right now. I know I've dealt with this issue before and was able to resolve it. Kind of difficult when I don't have IE9 to test with at the moment.

    Try Googling "IE9 center div issue" and you should find a ton of stuff! I'll try and come back tomorrow when I have my Vista machine available to see if you got it figured out.

Topic Closed

This topic has been closed to new replies.

About this Topic