Page 1 of 2 12 LastLast
Results 1 to 10 of 40

Hybrid View

  1. #1
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Hide What's New and Best Sellers Sideboxes

    Using your templates and overrides, customize the best_sellers.php sidebox with the code in red:
    Code:
    // bof: turn off best sellers on home page
    if ($this_is_home_page) { 
        $show_best_sellers= false;
    }  
    // eof: turn off best sellers on home page
    
      if ($show_best_sellers == true) {
    Customize the whats_new.php sidebox with the code in red:
    Code:
    // bof: turn off whats_new on home page
    if ($this_is_home_page) { 
        $show_whats_new= false;
    } else {
        $show_whats_new= true;
    }
    // eof: turn off whats_new on home page
    
    // display limits
    and then lower in the code:
    Code:
      if ($show_whats_new && $random_whats_new_sidebox_product->RecordCount() > 0 ) {
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  2. #2
    Join Date
    Dec 2009
    Posts
    244
    Plugin Contributions
    0

    Default Re: Hide What's New and Best Sellers Sideboxes

    Quote Originally Posted by Ajeh View Post
    Using your templates and overrides, customize the best_sellers.php sidebox with the code in red:
    Code:
    // bof: turn off best sellers on home page
    if ($this_is_home_page) { 
        $show_best_sellers= false;
    }  
    // eof: turn off best sellers on home page
    
      if ($show_best_sellers == true) {
    Customize the whats_new.php sidebox with the code in red:
    Code:
    // bof: turn off whats_new on home page
    if ($this_is_home_page) { 
        $show_whats_new= false;
    } else {
        $show_whats_new= true;
    }
    // eof: turn off whats_new on home page
    
    // display limits
    and then lower in the code:
    Code:
      if ($show_whats_new && $random_whats_new_sidebox_product->RecordCount() > 0 ) {
    I did as you said, but they are still on? The directory I altered the files in was:

    mysite.com/mytemplate/includes/modules/sideboxes/mytemplate/

    is this correct?

    If I add the code you metioned further down it shuts everything off on all the pages...$show_whats_new && $random_whats_new_sidebox_product->RecordCount() > 0 ) {

  3. #3
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Hide What's New and Best Sellers Sideboxes

    If you just do the Best Sellers sidebox ... does that work correctly?
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  4. #4
    Join Date
    Dec 2009
    Posts
    244
    Plugin Contributions
    0

    Default Re: Hide What's New and Best Sellers Sideboxes

    Quote Originally Posted by Ajeh View Post
    If you just do the Best Sellers sidebox ... does that work correctly?
    Best Sellers worked fine, just the "what's new" doesn't go off. I tried removing the else {
    $show_whats_new= true;

    code as that is the only difference in the "best seller" and "what's new" but nada...

  5. #5
    Join Date
    Dec 2009
    Posts
    244
    Plugin Contributions
    0

    Default Re: Hide What's New and Best Sellers Sideboxes

    I did as you said, but the "whats_new" is still on? The directory I altered the files in was:

    mysite.com/mytemplate/includes/modules/sideboxes/mytemplate/

    is this correct?

    If I add the code you mentioned further down in the "whats_new" file it shuts everything off on all the pages...$show_whats_new && $random_whats_new_sidebox_product->RecordCount() > 0 ) {

  6. #6
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Hide What's New and Best Sellers Sideboxes

    I don't know where your code is but this:
    mysite.com/mytemplate/includes/modules/sideboxes/mytemplate/

    is not a valid path ...

    you see the:
    /your_secret_admin
    /download
    /images
    /includes

    Now go to:
    /includes/modules/sideboxes

    copy the file:
    /includes/modules/sideboxes/whats_new.php

    to your templates and overrides directory for modules in:
    /includes/modules/sideboxes/your_template_dir/whats_new.php

    and then add the customizations ...

    follow the same method for the best_sellers.php ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  7. #7
    Join Date
    Dec 2009
    Posts
    244
    Plugin Contributions
    0

    Default Re: Hide What's New and Best Sellers Sideboxes

    Quote Originally Posted by Ajeh View Post
    I don't know where your code is but this:
    mysite.com/mytemplate/includes/modules/sideboxes/mytemplate/

    is not a valid path ...

    you see the:
    /your_secret_admin
    /download
    /images
    /includes

    Now go to:
    /includes/modules/sideboxes

    copy the file:
    /includes/modules/sideboxes/whats_new.php

    to your templates and overrides directory for modules in:
    /includes/modules/sideboxes/your_template_dir/whats_new.php

    and then add the customizations ...

    follow the same method for the best_sellers.php ...

    I do have the "What's New" and "Best Sellers" sideboxes in my template override folder located here:

    mysite.com/includes/modules/sideboxes/mytemplate/

    The alterations to "Best Sellers" works fine, but the "What's New" is no good...

  8. #8
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Hide What's New and Best Sellers Sideboxes

    Do you see errors or do you just see the What's New on the Home Page?
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

  9. #9
    Join Date
    Dec 2009
    Posts
    244
    Plugin Contributions
    0

    Default Re: Hide What's New and Best Sellers Sideboxes

    Quote Originally Posted by Ajeh View Post
    Do you see errors or do you just see the What's New on the Home Page?
    Just the what's new on the home page

  10. #10
    Join Date
    Apr 2008
    Posts
    151
    Plugin Contributions
    0

    Default Re: Hide What's New and Best Sellers Sideboxes

    Quote Originally Posted by Ajeh View Post
    Using your templates and overrides, customize the best_sellers.php sidebox with the code in red:
    [CODE]
    // bof: turn off best sellers on home page
    if ($this_is_home_page) {
    $show_best_sellers= false;
    }
    // eof: turn off best sellers on home page

    if ($show_best_sellers == true) {
    Hi Ajeh, thanks for your code suggestion, I also wanted to hide the bestsellers sidebox on my home page and the solution above worked fine. However, I just realized that I would prefer to have it shown only during product listing. So the customer easily can see the most sold products in the current category the customer is vewing. So I want to hide the bestsellers sidebox on for example "index.php?main_page=logoff", "index.php?main_page=reviews", "index.php?main_page=specials" etc... would love to see a code example where I can add the pages where I don't want the sidebox to show. Could use this for other sideboxes as well.

    Thanks!

    Best regards

    Peter

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v153 Intelligent All, Featured, Best Sellers, New, and Specials Links
    By mikeel100 in forum General Questions
    Replies: 1
    Last Post: 24 Nov 2015, 08:46 PM
  2. Can I choose what goes inside Best Sellers
    By dermit in forum General Questions
    Replies: 1
    Last Post: 16 Nov 2010, 07:40 AM
  3. Display "Best Sellers" like "What's New" or "Specials" lists.
    By jsmooth in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 22 Jun 2010, 12:06 AM
  4. Replies: 0
    Last Post: 1 Sep 2009, 11:26 PM
  5. Replace New Products Box w/ Best Sellers
    By mxer269 in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 11 Mar 2009, 04:36 PM

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