Results 1 to 5 of 5
  1. #1
    Join Date
    Jun 2007
    Posts
    61
    Plugin Contributions
    0

    Default Changing width and height of logo.gif

    Hi,

    I've been changing the logo image in header.php. This is all works fine and i can see my new image. I'm getting a few problems with changing the width and height. I tried changing the HEADER_LOGO_WIDTH and HEADER_LOGO_HEIGHT in header.php , but this did not changing the size of the image. When I did view source in the browser i could see that the width and height of <div id="logo"> where that of the original size of the gif image and not what i had entered into header.php.

    I did some more investigation and found the file tpl_header.php. I could see that this is where the html is created. I added in the HEADER_LOGO.. (width and height) to the correct line in this file and now the re-sizing works.

    So i've found out how to fix this but I was wondering why it was not working without my change to tpl_header.php.

    BTW I have created a new template folder and all changes to files were made under this folder/s.

    Thanks

  2. #2
    Join Date
    Jun 2007
    Posts
    19
    Plugin Contributions
    0

    Default Re: Changing width and height of logo.gif

    I am having the same issue, can you please post the correct line to put in the tpl_header as I am not great with php / css thanks

  3. #3
    Join Date
    Jan 2005
    Location
    Lake Havasu, AZ
    Posts
    1,149
    Plugin Contributions
    0

    Default Re: Changing width and height of logo.gif

    Actually, what you should have done is simply change the height of #LogoWrapper in your css - you don't need to mess with tpl_header at all.

    Look in your stylesheet and by default #LogoWrapper is set at 75px. you need to change that to the height of your logo and all should be well.

    HTH
    When the world gets in my face I say Have A Nice Day.
    * I DO Think and I HAVE BEEN Zenned - therefore, I AM * I donate - do you?
    Custom Templates and Zen Services CRS Designs, Inc.

  4. #4
    Join Date
    Jun 2007
    Posts
    19
    Plugin Contributions
    0

    Default Re: Changing width and height of logo.gif

    thanks for your help, changed logowrapper but it just altered the position.

    I then changing the following:


    #logo {
    width:19.1em /* To prevent the logo from resizing, simply delete or comment out this section */

    and that worked. Strange as I do not remember having to do this in my last install, I only had to edit header.php

    I am using the latest release of applezen so it could be an issue with that.

  5. #5
    Join Date
    Jun 2007
    Posts
    61
    Plugin Contributions
    0

    Default Re: Changing width and height of logo.gif

    Hi Zek,

    Yes, I thought that all you have to do is change the header.php file as this tutorial says:

    https://www.zen-cart.com/tutorials/i...hp?article=125

    So i agree, looks like something has changed here? what version are you using now and what version worked? I'm pretty new to this so I've only tried v1.3.7a, i think?

    the line i changed in tpl_header.php was this:

    <div id="logo"><?php echo '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . '">' . zen_image($template->get_template_dir(HEADER_LOGO_IMAGE, DIR_WS_TEMPLATE, $current_page_base,'images'). '/' . HEADER_LOGO_IMAGE, HEADER_ALT_TEXT, HEADER_LOGO_WIDTH, HEADER_LOGO_HEIGHT) . '</a>'; ?></div>

    I just added the HEADER_LOGO_WIDTH and HEADER_LOGO_HEIGHT to the end so it adds them into the html.

    Otherwise it seems that the defines in header.php are not used. Therefore changing them does nothing.

 

 

Similar Threads

  1. Icon.gif and Logo.gif
    By patwithds in forum General Questions
    Replies: 5
    Last Post: 27 Aug 2009, 05:48 PM
  2. Why change header logo width and height?
    By clueless_in_berlin in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 6 Feb 2009, 01:08 AM
  3. Resizing Logo.gif's Header Height
    By bendlikewillow in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 24 Jun 2008, 03:51 PM
  4. How do you change the Logo.gif width?
    By hankthtank in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 14 Mar 2008, 12:27 AM

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