Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / adding 2nd image to logo

adding 2nd image to logo

Locked

Views: 2,207

Results 21 to 34 of 34
This thread is locked. New replies are disabled.
16 Apr 2010, 2:24 PM
#21
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

adding 2nd image to logo

There is also a tpl_header.php file at

TTEZENCART/includes/templates/template_default/common/tpl_header.php.

Do you think I should make the same changes to that file as well.

16 Apr 2010, 2:28 PM
#22
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: adding 2nd image to logo

There is also a tpl_header.php file at

TTEZENCART/includes/templates/template_default/common/tpl_header.php.

Do you think I should make the same changes to tat file as well.
NO!! those are default core files
https://www.zen-cart.com/tutorials/index.php?article=346
https://www.zen-cart.com/tutorials/index.php?article=36

16 Apr 2010, 2:37 PM
#23
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

OK I understand.
So what do you think the problem is?
Why am I able to replicate the logo with the 2 separate images and not able to produce it live. I would prefer not going back to the single image I already had up. I'm at a total loss for answers.
Also I built my template override system as per your FAQ sheet, so I know its OK.

16 Apr 2010, 2:42 PM
#24
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: adding 2nd image to logo

I upload through Mozilla to:
/TTEZENCART/includes/templates/Tte/tpl_header.php
Did you move this file to the proper location?
/TTEZENCART/includes/templates/Tte/commom/tpl_header.php

16 Apr 2010, 3:04 PM
#25
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

I uploaded the file to the suggested area and it worked except that the nav line is added within the header.
go see http://30408.vws.magma.ca/ttezencart

16 Apr 2010, 3:44 PM
#26
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: adding 2nd image to logo

I still do not see this on the link or in the source???

no logo2

16 Apr 2010, 3:59 PM
#27
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

page source

<!--bof-branding display--> <div id="logoWrapper"> <div id="logo"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/tte_logo1.jpg" alt="" align="left" width="321" height="138"></a> <div id="logo2"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/btc_logo.jpg" alt="" align="right" width="321" height="138" /></a></div> </div>
16 Apr 2010, 5:37 PM
#28
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: adding 2nd image to logo

Appears that you have moved things outside of the normal divs that they belong in

<!--bof-header logo and navigation display-->


<!--eof-navigation display-->

<!--bof-branding display-->
<div id="logoWrapper"> This belongs indies of headerWrapper
    <div id="logo"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/tte_logo1.jpg" alt="" align="left" width="321" height="138"></a> 
   <div id="logo2"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/btc_logo.jpg" alt="" align="right" width="321" height="138" /></a></div>
</div>
<!--<br class="clearBoth" /> -->
<!--eof-branding display-->

<!--eof-header logo and navigation display-->

<!--bof-optional categories tabs navigation display-->
<div id="headerWrapper">
<!--bof-navigation display-->
<div id="navMainWrapper">

<div id="navMain">
    <ul class="back">
    <li><a href="http://30408.vws.magma.ca/TTEZENCART/">Home</a></li>
    <li><a href="http://30408.vws.magma.ca/TTEZENCART/index.php?main_page=login&">Log In</a></li>

</ul>
</div>This ends the navMain container

<div id="navMainSearch"><form name="quick_find_header" 
The above belongs inside of the navMain Div
action="http://30408.vws.magma.ca/TTEZENCART/index.php?main_page=advanced_search_result" method="get"><input type="hidden" name="main_page" value="advanced_search_result" /><input type="hidden" name="search_in_description" value="1" /><input type="hidden" name="zenid" value="72f3u718o12c46mrc2npipib93" /><input type="text" name="keyword" size="6" maxlength="30" style="width: 100px" value="Enter Keywords Here" onfocus="if (this.value == 'Enter Keywords Here') this.value = '';" onblur="if (this.value == '') this.value = 'Enter Keywords Here';" /> <input type="submit" value="Search" style="width: 45px" /></form></div>
<br class="clearBoth" /> 
</div>
And others
16 Apr 2010, 6:14 PM
#29
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

So soory for this mess:
Ive' entered what you suggested. This is what is actually in the php file, the upper part of what I added. Does this all need to be there. I'm getting a blank white sheet>

<!--bof-header logo and navigation display--> <?php if (!isset($flag_disable_header) || !$flag_disable_header) { ?> <!--eof-navigation display--> <!--bof-branding display--> <?php if (HEADER_SALES_TEXT != '' || (SHOW_BANNERS_GROUP_SET2 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET2))) { ?>
<div id="taglineWrapper">
<?php if (HEADER_SALES_TEXT != '') { ?>
  <div id="tagline"><?php echo HEADER_SALES_TEXT;?></div>
<?php } ?> <?php if (SHOW_BANNERS_GROUP_SET2 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET2)) { if ($banner->RecordCount() > 0) { ?>
  <div id="bannerTwo" class="banners"><?php echo zen_display_banner('static', $banner);?></div>
<?php } } ?>
</div>
<?php } // no HEADER_SALES_TEXT or SHOW_BANNERS_GROUP_SET2 ?> </div> <!--<br class="clearBoth" /> --> <!--eof-branding display--> <!--eof-header logo and navigation display--> <!--bof-optional categories tabs navigation display--> <div id="headerWrapper"> <div id="logoWrapper"> <div id="logo"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/tte_logo1.jpg" alt="" align="left" width="321" height="138"></a> <div id="logo2"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/btc_logo.jpg" alt="" align="right" width="321" height="138" /></a></div> <!--bof-navigation display--> <div id="navMainWrapper"> <div id="navMain"> <ul class="back"> <li><a href="http://30408.vws.magma.ca/TTEZENCART"/">Home</a></li> <li><a href="http://30408-vws.magma.ca/TTEZENCART/index.php?main_page=login&">Log In</a></li>
</ul>
</div>
<div id="navMainSearch"><form name="quick_find_header" action="http://30408.vws.magma.ca/TTEZENCART/index.php?main_page=advanced_search_result" method="get"><input type="hidden" name="main_page" value="advanced_search_result" /><input type="hidden" name="search_in_description" value="1" /><input type="hidden" name="zenid" value="72f3u718o12c46mrc2npipib93" /><input type="text" name="keyword" size="6" maxlength="30" style="width: 100px" value="Enter Keywords Here" onfocus="if (this.value == 'Enter Keywords Here') this.value = '';" onblur="if (this.value == '') this.value = 'Enter Keywords Here';" /> <input type="submit" value="Search" style="width: 45px" /></form></div> <br class="clearBoth" /> </div>
16 Apr 2010, 6:26 PM
#30
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

We are nearly there Kobra.
Now all that is showing is the Nav bar in the middle of both logo images.

There was a syntax error in the last upload.

16 Apr 2010, 6:36 PM
#31
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: adding 2nd image to logo

You need to do a couple of things and maybe starting with a fresh copy would be easiest - Now that you have things where they belong
And just insert your additional div - code and closing div

<div id="logo2"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/btc_logo.jpg" alt="" align="right" width="321" height="138" /></a></div>

The above is all that you should have to add
Leave this (in green)as is - - with your added in red

<!--bof-branding display-->
<div id="logoWrapper">
    <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) . '</a>'; ?></div>

<div id="logo2"><a href="http://30408.vws.magma.ca/TTEZENCART"><img src="http://30408.vws.magma.ca/TTEZENCART/includes/templates/Tte/images/btc_logo.jpg" alt="" align="right" width="321" height="138" /></a></div>

<?php if (HEADER_SALES_TEXT != '' || (SHOW_BANNERS_GROUP_SET2 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET2))) { ?>
    <div id="taglineWrapper">
<?php
              if (HEADER_SALES_TEXT != '') {
?>
      <div id="tagline"><?php echo HEADER_SALES_TEXT;?></div>
<?php
              }
?>
<?php
              if (SHOW_BANNERS_GROUP_SET2 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET2)) {
                if ($banner->RecordCount() > 0) {
?>
      <div id="bannerTwo" class="banners"><?php echo zen_display_banner('static', $banner);?></div>
<?php
                }
              }
?>
    </div>
<?php } // no HEADER_SALES_TEXT or SHOW_BANNERS_GROUP_SET2 ?>
</div>
<br class="clearBoth" />
<!--eof-branding display-->

Then edit /includes/languages/english/Tte/header.php

// added defines for header alt and text
  define('HEADER_ALT_TEXT', 'Powered by Zen Cart :: The Art of E-Commerce');
  define('HEADER_SALES_TEXT', 'TagLine Here');
  define('HEADER_LOGO_WIDTH', '321px');
  define('HEADER_LOGO_HEIGHT', '138px');
  define('HEADER_LOGO_IMAGE', 'tte_logo1.jpg');
16 Apr 2010, 7:24 PM
#32
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

I add the suggested text and everything else as shown then I get a header that is completely out of sync. everything is basically duplicated.I've returned it to previous state.

At this point all I need to do is move the Black center box, below the logos in form of a horizontal black line that has the Home Log In on the left side and the search box on the left side of that line.

Sorry for all this time and effort on your part, I am extremely greatful and will reciprocate with a generous donation as soon as we finish this project.

One more question what is the reason to change the header.php file?

16 Apr 2010, 7:33 PM
#33
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: adding 2nd image to logo

I add the suggested text and everything else as shown then I get a header that is completely out of sync. everything is basically duplicated.I've returned it to previous state.
Did not get to see this - - Using src's with http: will cause issues later on all secure pages
Myself:

This src, if you can not make it relative or https will have to be dealt with on your cart https pages
And is why I suggested you get back to using the functionality builtin to ZenCart

16 Apr 2010, 7:49 PM
#34
robertg avatar

robertg

Zen Follower

Join Date:
Nov 2009
Posts:
341
Plugin Contributions:
0

Re: adding 2nd image to logo

kobra:

Did not get to see this - - Using src's with http: will cause issues later on all secure pages

And is why I suggested you get back to using the functionality builtin to ZenCart

I guess I'm acting like a newbie but I am really getting confused with your 2 quotes above. I really don't understand what you are trying to explain. sorry.
I just did a view page source on my site and have all kinds of extra text etc, that I had never seen before.
What's going on, Please explain.