osCmax v2.5 User Manual
Results 1 to 9 of 9

Taking out right column boxes

This is a discussion on Taking out right column boxes within the osCMax v1.7 General Mods Discussion forums, part of the osCmax v1.7 Forums category; I don't know how to take out some of the boxes (sorry, don't know what they're called) on the right ...

      
  1. #1
    New Member
    Join Date
    Oct 2004
    Posts
    16
    Rep Power
    0


    Default Taking out right column boxes

    I don't know how to take out some of the boxes (sorry, don't know what they're called) on the right column. These are the categories I want to delete:

    -manufacture info
    -currencies
    -languages
    -tell a friend
    -review

    I looked everywhere, but still don't know. Also, is there a way to take out the "click to enlarge" option? I can't get it to work, so I'm putting the images in the HTML.

    Any help would be appreciated. Thanks

  2. #2
    Active Member red_fraggle's Avatar
    Join Date
    Feb 2004
    Location
    wilmington, NC
    Posts
    343
    Rep Power
    9


    Default RE: Taking out right column boxes

    open file /includes/column_right.php and comment the boxes you dont want out using the standard php comment tag of "//" before any require statements for the boxes you want gone.

    Open product_info.php and edit the code to remove the hyperlink for the "click to enlarge".

  3. #3
    New Member
    Join Date
    Oct 2004
    Posts
    16
    Rep Power
    0


    Default Thanks

    Thanks, I really appreciate it. I was going crazy.

  4. #4
    New Member
    Join Date
    Oct 2004
    Posts
    16
    Rep Power
    0


    Default Wait, gotta make sure

    Ok, I looked at it and I just want to make sure that I understood what you explained.

    So when it says "manufacture_info" I'll replace it with "//" right?

    Also, for the click to enlarge issue, how do I edit the code to remove the hyperlink? I was thinking I just had to erase something and then I read your sentence again.

    Thanks for the help.

  5. #5
    Lurker
    Join Date
    Feb 2005
    Posts
    2
    Rep Power
    0


    Default No, slashes are used to comment out a command

    Place the slashes after <?php and before the include directive:
    Code:
    <?php  //include(DIR_WS_BOXES . 'manufacturers.php'); ?>

  6. #6
    New Member
    Join Date
    Oct 2004
    Posts
    16
    Rep Power
    0


    Default Any answer about editing "enlarge image" code?

    How do you edit the code for the "enlarge image" to get rid of it? I received this reply:

    Open product_info.php and edit the code to remove the hyperlink for the "click to enlarge".

    I don't know how to edit the code.

    Thanks

  7. #7
    Active Member red_fraggle's Avatar
    Join Date
    Feb 2004
    Location
    wilmington, NC
    Posts
    343
    Rep Power
    9


    Default RE: Any answer about editing "enlarge image" code?

    Easy Way:

    /catalog/includes/languages/english/product_info.php find code:
    Code:
    define('TEXT_CLICK_TO_ENLARGE', 'Click to enlarge');
    and change it to this:
    Code:
    define('TEXT_CLICK_TO_ENLARGE', '');
    this will only remove the text "click here to enlarge" the image remains a link to the popup.

    Harder Way:
    if using MAX 1.7 open /templates/templatename/product_info.tpl.php and look for this code around line 86

    Code:
    <script language="javascript"><!--
    document.write('<?php echo '<a href="javascript:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id']) . '\\\')">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>'; ?>');
    //--></script>
    <noscript>
    <?php echo '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image']) . '" target="_blank">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>'; ?>
    </noscript>
    Change it to this
    Code:
    <script language="javascript"><!--
    document.write('<?php echo tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"'); ?>');
    //--></script>
    <noscript>
    <?php echo tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'hspace="5" vspace="5"'); ?>
    </noscript>

    This will remove the text from the screen and prevent the image from being a link itself as well.

  8. #8
    New Member
    Join Date
    Oct 2004
    Posts
    16
    Rep Power
    0


    Default Still can't get rid of right colum categories

    I tried to follow the instructions given to me, but maybe I'm doing something wrong. Don't know anything about php, so I need all the help I can get. This is what's in the include/column_right.php section:

    <?php
    /*
    $Id: column_right.php,v 1.17 2003/06/09 22:06:41 hpdl Exp $

    osCommerce, Open Source E-Commerce Solutions
    http://www.oscommerce.com

    Copyright (c) 2003 osCommerce

    Released under the GNU General Public License
    */

    require(DIR_WS_BOXES . 'shopping_cart.php');

    if (isset($HTTP_GET_VARS['products_id'])) include(DIR_WS_BOXES . 'manufacturer_info.php');

    if (tep_session_is_registered('customer_id')) include(DIR_WS_BOXES . 'order_history.php');

    if (isset($HTTP_GET_VARS['products_id'])) {
    if (tep_session_is_registered('customer_id')) {
    $check_query = tep_db_query("select count(*) as count from " . TABLE_CUSTOMERS_INFO . " where customers_info_id = '" . (int)$customer_id . "' and global_product_notifications = '1'");
    $check = tep_db_fetch_array($check_query);
    if ($check['count'] > 0) {
    include(DIR_WS_BOXES . 'best_sellers.php');
    } else {
    include(DIR_WS_BOXES . 'product_notifications.php');
    }
    } else {
    include(DIR_WS_BOXES . 'product_notifications.php');
    }
    } else {
    include(DIR_WS_BOXES . 'best_sellers.php');
    }

    if (isset($HTTP_GET_VARS['products_id'])) {
    if (basename($PHP_SELF) != FILENAME_TELL_A_FRIEND) include(DIR_WS_BOXES . 'tell_a_friend.php');
    } else {
    include(DIR_WS_BOXES . 'specials.php');
    }

    require(DIR_WS_BOXES . 'reviews.php');

    if (substr(basename($PHP_SELF), 0, != 'checkout') {
    include(DIR_WS_BOXES . 'languages.php');
    include(DIR_WS_BOXES . 'currencies.php');
    }
    ?>

    So where do I place the "//"?

  9. #9
    Active Member red_fraggle's Avatar
    Join Date
    Feb 2004
    Location
    wilmington, NC
    Posts
    343
    Rep Power
    9


    Default RE: Still can

    the standard characters to "comment" out code in php is // this means for any boxes you want removed you will need to add a "//" before them above. An example would be if you wanted to remove the "languages" info box from the right_column of your store, above you would change the line:

    Code:
    include(DIR_WS_BOXES . 'languages.php');
    to:

    Code:
    // include(DIR_WS_BOXES . 'languages.php');
    Now that your using a shopping cart system written in PHP, it might be wise to get a book on PHP and mysql Anyway hope this helps.

Similar Threads

  1. Boxes and left column help please
    By countingsheep in forum osCmax v2 Customization/Mods
    Replies: 2
    Last Post: 08-31-2006, 03:20 PM
  2. taking advantage of dynamic meta tags
    By humanode in forum osCMax v2 Features Discussion
    Replies: 2
    Last Post: 11-24-2005, 06:28 PM
  3. non-permanent way of moving boxes from one column to another
    By innovations in forum osCommerce 2.2 Modification Help
    Replies: 1
    Last Post: 12-17-2004, 03:37 PM
  4. Move all in rh column to left and remove RH column
    By jloyzaga in forum osCmax v1.7 Discussion
    Replies: 0
    Last Post: 03-24-2004, 03:24 PM
  5. Taking OSCommerce off site?
    By WebMistress in forum osCommerce 2.2 Modification Help
    Replies: 1
    Last Post: 11-12-2003, 03:31 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
  •