Results 1 to 5 of 5

Hybrid View

  1. #1
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Disable left & right columns on category listing pages?

    What would the correct IF statement to Disable left & right columns on category listing pages?

    when I say category listing pages I mean listings of categories only, not the product listing pages.

    Thanks in advance.

    Phil
    Phil Rogers
    A problem shared is a problem solved.

  2. #2
    Join Date
    Jan 2006
    Posts
    420
    Plugin Contributions
    0

    Default Re: Disable left & right columns on category listing pages?

    You could use something like this :


    Code:
    if ($cPath == '2' or $cPath == '3') {
    $flag_disable_right = true;
    $flag_disable_left = true;
     }
    I thought about using if cPath > 0 , but that would work on every page , and not what you want.

    The best way would be if you have alot of cats is to make the cat listing into an array. and call that array to disable the side columns
    Various Zen cart sites !

  3. #3
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    13,874
    Plugin Contributions
    96

    Default Re: Disable left & right columns on category listing pages?

    You could use this code fragment to cause the left and right columns to be disabled in a category listing page, but displayed on a product listing page:
    Code:
    if ($_GET['main_page'] == FILENAME_DEFAULT && zen_not_null($category_depth) && $category_depth != 'products') {
      $flag_disable_left = true;
      $flag_disable_right = true;
    }

  4. #4
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Disable left & right columns on category listing pages?

    Quote Originally Posted by lat9 View Post
    You could use this code fragment to cause the left and right columns to be disabled in a category listing page, but displayed on a product listing page:
    Code:
    if ($_GET['main_page'] == FILENAME_DEFAULT && zen_not_null($category_depth) && $category_depth != 'products') {
      $flag_disable_left = true;
      $flag_disable_right = true;
    }
    will give this a go, thats what I need I think. cheers
    Phil Rogers
    A problem shared is a problem solved.

  5. #5
    Join Date
    Aug 2009
    Location
    Bedford, England
    Posts
    966
    Plugin Contributions
    0

    Default Re: Disable left & right columns on category listing pages?

    Quote Originally Posted by lat9 View Post
    You could use this code fragment to cause the left and right columns to be disabled in a category listing page, but displayed on a product listing page:
    Code:
    if ($_GET['main_page'] == FILENAME_DEFAULT && zen_not_null($category_depth) && $category_depth != 'products') {
      $flag_disable_left = true;
      $flag_disable_right = true;
    }
    worked a treat Cheers!
    Phil Rogers
    A problem shared is a problem solved.

 

 

Similar Threads

  1. Right & Left Columns are empty, please help ASAP
    By JDuval in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 8 Mar 2012, 08:00 AM
  2. Possible to turn off left & right columns based on page type?
    By edwardtilbury in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 17 Mar 2009, 04:33 AM
  3. Hide left and right columns on main_page...
    By Alex Clarke in forum General Questions
    Replies: 6
    Last Post: 8 Dec 2006, 10:26 PM
  4. Attributes columns, Left and Right
    By broknspyrl in forum Setting Up Categories, Products, Attributes
    Replies: 1
    Last Post: 12 Aug 2006, 07:21 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