Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 2007
    Location
    Washington
    Posts
    115
    Plugin Contributions
    0

    Default Add Log In Link to Product Page (Below the product name & price)

    Hi. I'm hoping to add a Log In / Log Out link on the product page.
    I'd want it right below the Product Name and Product Price.

    My guess is this will go into the tpl_product_info_display.php file, but wouldn't want to assume anything, not being a code-master.

    Is there a fairly simple way to accomplish this?

    Thanks for any help!

    Cris
    Cris

  2. #2
    Join Date
    Jan 2004
    Posts
    66,374
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: Add Log In Link to Product Page (Below the product name & price)

    Quote Originally Posted by cleverpork View Post
    Hi. I'm hoping to add a Log In / Log Out link on the product page.
    If it's ONLY for convenience, and you do indeed want them to be taken to the Login or Logout page, then yes the right file is the tpl_product_info_display.php file.
    Something like the following would need to be put into the file at whatever point where you want the link to show.
    Code:
    <?php if ($_SESSION['customer_id']) { ?>
        <a href="<?php echo zen_href_link(FILENAME_LOGOFF, '', 'SSL'); ?>">Logoff</a>
    <?php
          } else {
    ?>
        <a href="<?php echo zen_href_link(FILENAME_LOGIN, '', 'SSL'); ?>">Login</a>
    <?php } ?>
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

 

 

Similar Threads

  1. v150 On Product Display Page add text before Price when using Qty Discount & change Price
    By rufusclc in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 4 Jun 2013, 08:04 PM
  2. Replies: 0
    Last Post: 10 Oct 2011, 12:39 AM
  3. Missing product name & product price from Product Info Page
    By kpatterson in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 16 Feb 2011, 03:11 AM
  4. Product Info page: Name, Price, Model, Attribs & Add to Cart in one table?
    By miles in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 7 Jul 2008, 05:02 AM
  5. Move Add to Cart Below Product Price on Product Info Page
    By dave_nextexit in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 15 Apr 2008, 09:20 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