Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2004
    Location
    Iowa
    Posts
    84
    Plugin Contributions
    0

    Default How to Make the LOGO link point to the website home page in parent folder.

    I did find a very similar thread about this that was closed. But I thought a new thread about this specific question might be beneficial to more than just me.

    So I have my zen-cart installed in a subfolder ../store And I'm getting complaints from customers that they can't get back to my website home page once they have selected to enter the online store. Even though I named a box "Important Link" with a choice that titled "Website Home Page" and forced the box to be the top most box on all pages of the shopping cart. LOL.. It falls back to people expecting the company logo to be a link to the website home page. (Just FYI, I'm using the HOPE template from Zen4Me) Having been a long time ZC user I'm very much against doing any customizing that could be overwritten by upgrading my ZC install. Especially since I know I'm getting close to being forced to upgrade being on such an older version still. SO, my question to those who know the ZC setup infinitely better than I... :-)

    How can I make the LOGO of my ZC link to the index.html file in the parent folder from my store? (www.mydomain.com/index.html) And hopefully without altering any ZC files. (I'm OK with altering template files)


    Oh My! I think I answered my own question here.

    In my /includes/templates/<template_name>/common folder is a file named tpl_header.php and inside that file is a section that is...
    Code:
                <!-- EDIT/INSERT YOUR LOGO BELOW --> 
                            <div id="zm_logo">
                            <div class="zm_logo_font">
                                <a href="<?php echo zen_href_link(FILENAME_DEFAULT); ?>" title="<?php echo STORE_NAME;?>">
                                    <img src="<?php echo DIR_WS_TEMPLATE_IMAGES;?>logo.png" />
                                </a>    
                            </div>
                            </div>
                            
                <!-- END LOGO -->
    I changed it to be this
    Code:
     <!-- EDIT/INSERT YOUR LOGO BELOW --> 
                            <div id="zm_logo">
                            <div class="zm_logo_font">
                                <a href="http://mydomain.com" title="My Company Name Home Page">
                                    <img src="<?php echo DIR_WS_TEMPLATE_IMAGES;?>logo.png" />
                                </a>    
                            </div>
                            </div>
                            
                <!-- END LOGO -->
    And after testing that in fact did work. I may have to promote myself to answering questions here instead of asking them. LOL

    Thanks for looking and my problem and my solution. If you have a more elegant or alternate method for solving this problem I welcome your comments.

  2. #2
    Join Date
    Jul 2012
    Posts
    16,710
    Plugin Contributions
    17

    Default Re: How to Make the LOGO link point to the website home page in parent folder.

    Unfortunately the more "elegant" solution would probably take a lot of work. Ideally, since you're in business to make money, everything on you're "site" would be served up through ZC and therefore the "homepage" would still be the root of your site as well as just one more step off point to make money.

    Otherwise, if you wanted to maintain your template "server location" proof, if instead of typing in the URI to your site, if you used a check of $request_type ='SSL' you could echo HTTPS_SERVER or HTTP_SERVER respectfully thus if you use the template on another domain name then it will always go back to what is defined in includes/configure.php and use the portability of ZC to ts advantage rather than having to find where all the hardcoded links are within your template/files.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. How to make the HOME page (index) different than the STORE page (main page)?
    By Dianna668 in forum Templates, Stylesheets, Page Layout
    Replies: 14
    Last Post: 27 Apr 2011, 05:29 PM
  2. How to make the link point to php file?
    By andrewmax81 in forum General Questions
    Replies: 10
    Last Post: 24 Dec 2009, 01:16 PM
  3. Replies: 3
    Last Post: 23 Sep 2008, 06:25 PM
  4. How can I make my site logo be a link to home?
    By DanAllkins in forum Templates, Stylesheets, Page Layout
    Replies: 9
    Last Post: 16 May 2008, 01:03 AM
  5. Replies: 1
    Last Post: 30 May 2006, 06:51 PM

Bookmarks

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
Zen-Cart, Internet Selling Services, Klamath Falls, OR