Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2007
    Posts
    72
    Plugin Contributions
    0

    Default Sidebox only in contact us page ...

    Help!!!

    I'm trying to have sideboxes appear only in my contact page ...

    here is the goofy code that I came up with for my module ...


    PHP Code:
    <?php
    /**
     * indexright sidebox
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
      * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $
     */

      // test if box should display
    $show_contactusright_sidebox false;

    if (!(
    $_GET['main_page']==FILENAME_CONTACT_US)) $show_contactusright_sidebox true;

     if (
    $show_contactusright_sidebox == true) {
          require(
    $template->get_template_dir('tpl_indexright_sidebox.php',DIR_WS_TEMPLATE$current_page_base,'sideboxes'). '/tpl_indexright_sidebox.php');
          
    $title =  BOX_HEADING_CONTACTUS_SIDEBOX;
          
    $title_link false;
          require(
    $template->get_template_dir($column_box_defaultDIR_WS_TEMPLATE$current_page_base,'common') . '/' $column_box_default);
     }

     
    ?>
    Last edited by monkeyjr47906; 14 Dec 2007 at 04:13 PM. Reason: Don't know how to enter code.

  2. #2
    Join Date
    Oct 2006
    Posts
    5,477
    Plugin Contributions
    11

    Default Re: Sidebox only in contact us page ...

    PHP Code:
     $show_contactusright_sidebox false;

    if (!(
    $_GET['main_page']==FILENAME_CONTACT_US)) $show_contactusright_sidebox true;

     if (
    $show_contactusright_sidebox == true) { 
    Why don't you put them all in just one IF?

    And your code is saying that: if the page is NOT contact_us then display.
    I no longer provide installation support on forum for all my modules. However, if there are real bugs with the modules please feel free to contact me

  3. #3
    Join Date
    Nov 2007
    Posts
    72
    Plugin Contributions
    0

    Default Re: Sidebox only in contact us page ...

    I had a typo (not that it makes a difference) in the first post ...

    Help!!!

    I'm trying to have sideboxes appear only in my contact page ...

    here is the goofy code that I came up with for my module ...


    PHP Code:
    <?php
    /**
     * indexright sidebox
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
      * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $
     */

      // test if box should display
    $show_contactusright_sidebox false;

    if (!(
    $_GET['main_page']==FILENAME_CONTACT_US)) $show_contactusright_sidebox true;

     if (
    $show_contactusright_sidebox == true) {
          require(
    $template->get_template_dir('tpl_contactusright_sidebox.php',DIR_WS_TEMPLATE$current_page_base,'sideboxes'). '/tpl_contactusright_sidebox.php');
          
    $title =  BOX_HEADING_CONTACTUS_SIDEBOX;
          
    $title_link false;
          require(
    $template->get_template_dir($column_box_defaultDIR_WS_TEMPLATE$current_page_base,'common') . '/' $column_box_default);
     }

     
    ?>

  4. #4
    Join Date
    Nov 2007
    Posts
    72
    Plugin Contributions
    0

    Default Re: Sidebox only in contact us page ...

    Alright YELLOW!!!!

    I'm dead serious about this ... pick and CD on amazon.com and its yours...please no box sets!

    I've been beating my head against a wall trying to figure this ba5tard out. (which shows how much of a rookie you're dealing with)

  5. #5
    Join Date
    Oct 2006
    Posts
    5,477
    Plugin Contributions
    11

    Default Re: Sidebox only in contact us page ...

    Lol

    Try this:

    PHP Code:
     <?php 
    /** 
     * indexright sidebox 
     * 
     * @package templateSystem 
     * @copyright 2007 Kuroi Web Design 
      * @copyright Portions Copyright 2003-2007 Zen Cart Development Team 
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0 
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $ 
     */ 

      // test if box should display 
    if ($_GET['main_page']==FILENAME_CONTACT_US){
          require(
    $template->get_template_dir('tpl_contactusright_sidebox.php',DIR_WS_TEMPLATE$current_page_base,'sideboxes'). '/tpl_contactusright_sidebox.php'); 
          
    $title =  BOX_HEADING_CONTACTUS_SIDEBOX
          
    $title_link false
          require(
    $template->get_template_dir($column_box_defaultDIR_WS_TEMPLATE$current_page_base,'common') . '/' $column_box_default); 
     } 

      
    ?>
    I no longer provide installation support on forum for all my modules. However, if there are real bugs with the modules please feel free to contact me

  6. #6
    Join Date
    Nov 2007
    Posts
    72
    Plugin Contributions
    0

    Default Re: Sidebox only in contact us page ...

    worked fine! man i can't tell you how much i appreciate it!

  7. #7
    Join Date
    Oct 2006
    Posts
    5,477
    Plugin Contributions
    11

    Default Re: Sidebox only in contact us page ...

    You are welcome ^^.
    I no longer provide installation support on forum for all my modules. However, if there are real bugs with the modules please feel free to contact me

 

 

Similar Threads

  1. v150 Sidebox on one ez page ID only
    By buildingblocks in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 29 Feb 2012, 12:52 AM
  2. Disable Specials Sidebox On Contact Us Page
    By wdd49 in forum Addon Sideboxes
    Replies: 3
    Last Post: 10 Oct 2010, 07:19 PM
  3. Error with fieldset on contact page only effecting IE, cannot figure it out at all
    By nigelt74 in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 25 Aug 2010, 09:47 PM
  4. Disable Catalog sidebox when in Contact Us page
    By jameslo in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 25 Feb 2008, 09:32 AM
  5. Only show sidebox on ez-page #x
    By SHK in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 23 Nov 2006, 05:03 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