This is a discussion on how to expand the categories in home page within the osCMax v2 Features Discussion forums, part of the osCMax v2.0 Forums category; Dear sir In the home page I wish to have the products diplayed by default under the various categories category ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| Dear sir In the home page I wish to have the products diplayed by default under the various categories category one product 1 product 2 how can i do. is there a contribution. i cannot locate it. thanks a million. ashok |
| Sponsored Links | ||
| ||
|
#2
| |||
| |||
| Dear friends i found this in oscommerce contributions. This creates a drop down of products in the home page. a) Just save it in as products_drop.php and upload to catalog/includes/boxes. <?php /* osCommerce, Open Source E-Commerce Solutions osCommerce, Open Source Online Shop E-Commerce Solutions Copyright (c) 2001 osCommerce Released under the GNU General Public License */ ?> <tr> <td> <?php new infoBox($info_box_contents, false, false); $products_query = tep_db_query("select p.products_id, pd.products_name, c.categories_id, cd.categories_name, p2c.categories_id, p2c.products_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c where p.products_id = pd.products_id and c.categories_id = cd.categories_id and p.products_id = p2c.products_id and c.categories_id = p2c.categories_id and pd.language_id = '" . (int)$languages_id . "' and cd.language_id = '" . (int)$languages_id . "' order by pd.products_name"); if ($number_of_rows = tep_db_num_rows($products_query)) { $products_array = array(); $products_array[] = array('id' => '', 'text' => 'Select Product'); while ($products = tep_db_fetch_array($products_query)) { $products_name = $products['products_name'] . ' - ' . $products['categories_name']; $products_array[] = array('id' => $products['products_id'], 'text' => $products_name); } $info_box_contents = array(); $info_box_contents[] = array('form' => tep_draw_form('products', tep_href_link(FILENAME_PRODUCT_INFO, '', 'NONSSL', false), 'get'), 'text' => tep_draw_pull_down_menu('products_id', $products_array, (isset($HTTP_GET_VARS['products_id']) ? $HTTP_GET_VARS['products_id'] : ''), 'onChange="this.form.submit();" size="' . MAX_PRODUCTS_LIST . '" style="width: 200"') . tep_hide_session_id()); new infoBox($info_box_contents); } ?> </td> </tr> b) write a code in catalog/includes/column_left.php or in catalog/includes/column_right.php before ?> or a anywhere between <?php ---- ?> include(DIR_WS_BOXES . 'products_drop.php'); --------------------------------------------------------------- My requirement is not a drop down but a list of products. how do i achieve it. regards ashok |
| Sponsored Links | ||
| ||
| Thread Tools | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| home page; what should it be? | nicki-jo | osCMax v2 Installation issues | 1 | 05-03-2007 07:02 PM |
| Categories Images on Home Page | yulises | osCMax v2 Customization/Mods | 2 | 03-28-2007 08:39 AM |
| Product detail page as the home/main page??? | sukarya | osCommerce 2.2 Modification Help | 1 | 02-17-2006 06:21 AM |
| how can I add a log in form to my home page... | fer_75 | osCommerce 2.2 Discussion | 7 | 08-11-2005 06:14 AM |
| Catagories on the home page! | pthurmond | osCMax v1.7 General Mods Discussion | 3 | 08-01-2005 10:47 AM |