Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2008
    Posts
    59
    Plugin Contributions
    0

    Default Problem with switching columns on/off

    Hi,

    I'm having trouble with switching columns on/off on the home page and category lists. I have added the code if tpl_main_page file (see below) to switch off columns for the home page and it works fine, BUT...it also switches them off on the category lists which I don't want. Not too hot with PHP so not sure how to add the extra code to ensure that it is only switched off for the home page.

    // the following IF statement can be duplicated/modified as needed to set additional flags
    if (in_array($current_page_base,explode(",",'contact_us,conditions,index')) ) {
    $flag_disable_right = true;
    }
    // the following IF statement can be duplicated/modified as needed to set additional flags
    if (in_array($current_page_base,explode(",",'conditions,index')) ) {
    $flag_disable_left = true;
    }
    Cheers,
    Adam.

  2. #2
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Problem with switching columns on/off

    The easiest way to affect the home page is to use
    PHP Code:
    if ($this_is_home_page) {
      
    $flag_disable_left true;
      
    $flag_disable_right true;


  3. #3
    Join Date
    Jul 2008
    Posts
    59
    Plugin Contributions
    0

    Default Re: Problem with switching columns on/off

    Worked perfectly - thank you Glenn, much appreciated

 

 

Similar Threads

  1. Turning off columns issues with if(cpath ....
    By monkeyjr47906 in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 20 Oct 2010, 07:31 PM
  2. Problem with products not switching off when out of stock..
    By philip937 in forum General Questions
    Replies: 12
    Last Post: 13 Oct 2009, 09:07 PM
  3. help with problem after switching server
    By wii4u32 in forum Upgrading from 1.3.x to 1.3.9
    Replies: 1
    Last Post: 20 Oct 2008, 06:07 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