chrometweaks.org

Help me! please help me! Is iPage and Basic Fusion, Inc connected?

Click Here To View All Answers...


Quick question... Help me! please help me! Is iPage and Basic Fusion, Inc connected? Thanks for any response. Another quick question... Has anyone had this problem....

I have categories and sub categories, Some catergries when clicked it shows the default page with the sub categories with it's pictures and also Products for that month. BUT I have some categories that when click it just shows the list of all the products and not the sub categories.....

Any Idea's need help please.

Thanks. :cry:..

Comments (118)

I'm stumped. I'm not so sure what is the right answer to your question. I'll do some Googling and get back to you if I discover an good answer. You should email the people at iPage as they probably could answer your iPage question..

Comment #1

Sorry.. I do not have a live iPage site to see, I still have a test iPage site on my PC....

Comment #2

HI TB,.

The Strange thing is that I have the orginal sample products and sub categories, and they have products in the sub categories and some without. And those 3 examples are just fine, but I have put my own categories and subcategories and when I click on the categories, it just shows me the list of all the products and not subcategories...

I had a look at your iPage site and that is similar to what I am seeking when you click for example on your Headsets it shows the subcategories with the pictures then when you click the any of them that shows the products just what I am looking for..

I will try the contribute link you advised, thanks...

Oh another question how did you get the products to show in the images like you have..

Thanks.

Prash..

Comment #3

Do you mean how my products are shown in rows with images like.

Here.

, rather than the standard column..

Or how the images are shown next to the product description like.

Here.

?.

The first is a really easy contribution to install..

It's called.

Column Product Listing.

, and can be found here:.

Http://www.oscommerc...ntributions,825.

The second is a modified version of.

Dynamic MoPics.

, which can be found here:.

Http://www.oscommerc...tributions,1114.

The two modules above are not all that hard to install. If you would rather wait though, I have been packaging many contributions and modifications together and will be releasing.

Modosc.

, shortly after the official osCommerce MS2 is released..

There are some details of the contributions installed, and a screen shot of the admin interface here:.

Http://forums.oscommerce.com/viewtopic.php...r=asc&start;=100.

HTH,.

Tony..

Comment #4

HI,.

Yes the frist contribution, thanks for the link and sure I will wait for your contribution looks easy to control and handle... Is there a seperate mod to show the contribution you have installed. As that is a good tool to use... If I am ask about your wish list did you use Wishlist MS1. as I have installed that but with no luck it does not really work well, when you click on the product to add to the wish list it jsut show 0.00 as the value and then it goes to the cart and indicate the cart is emply.. this is just on the fly question as I have contacted the guy who contributed this mod, but no luck.. anyways thanks for the help...

Comment #5

HI , this mod is giving me an error....

Error:.

Fatal error: Cannot pass parameter 3 by reference in C:Inetpubwwwrootstorecatalogincludesmodulesproduct_listing.php on line 13.

Any ideas!..

Comment #6

I will be releasing the package as a complete modified version of MS2. The package wil have the screen shot shown as a standard feature. One look at the screen will show you what features/contributions you have activate or not..

As for the Wishlist, I was doing testing with that today. I uploaded my local database where I had the Wishlist set to true, though this isn't what I wanted for my live store..

I have used the latest version, though I am still having SQL problems with the main wishlist.php page. When I get a chance, I will be looking at this also... until then, I will use the admin interface to give it a little click on 'false'..

I'm not sure if I cam across the same error as yourself with that file, though here is my entire file..

<?php.

/*.

 $Id: product_listing.php,v 1.44 2003/06/09 22:49:43 hpdl Exp $.

 osCommerce, Open Source E-Commerce Solutions.

 http://www.oscommerce.com.

 Copyright (c) 2003 osCommerce.

 Released under the GNU General Public License.

*/.

 $listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_SEARCH_RESULTS, 'p.products_id');.

 if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) {.

?>.

<table border="0" width="100%" cellspacing="0" cellpadding="2">.

 <tr>.

   <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td>.

   <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE' '$listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td>.

 </tr>.

</table>.

<?php.

 }.

 $list_box_contents = array();.

 if ($listing_split->number_of_rows > 0) {.

   $listing_query = tep_db_query($listing_split->sql_query);.

   $row = 0;.

   $column = 0;.

   while ($listing = tep_db_fetch_array($listing_query)) {.

     $product_contents = array();.

     for ($col=0, $n=sizeof($column_list); $col<$n; $col++) {.

       $lc_align = '';.

       switch ($column_list[$col]) {.

         case 'PRODUCT_LIST_MODEL':.

           $lc_align = '';.

           $lc_text = '&nbsp;'$listing['products_model']'&nbsp;';.

           break;.

         case 'PRODUCT_LIST_NAME':.

           $lc_align = '';.

           if (isset($HTTP_GET_VARS['manufacturers_id'])) {.

             $lc_text = '<a href="'tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id='$HTTP_GET_VARS['manufacturers_id']'&products_id='$listing['products_id'])'">'$listing['products_name']'</a>';.

           } else {.

             $lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath='$cPath'&' : '')'products_id='$listing['products_id'])'">'$listing['products_name']'</a>&nbsp;';.

           }.

           break;.

         case 'PRODUCT_LIST_MANUFACTURER':.

           $lc_align = '';.

           $lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_DEFAULT, 'manufacturers_id='$listing['manufacturers_id'])'">'$listing['manufacturers_name']'</a>&nbsp;';.

           break;.

         case 'PRODUCT_LIST_PRICE':.

           $lc_align = 'right';.

           if (tep_not_null($listing['specials_new_products_price'])) {.

             $lc_text = '&nbsp;<s>' $currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'</s>&nbsp;&nbsp;<span class="productSpecialPrice">'$currencies->display_price($listing['specials_new_products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'</span>&nbsp;';.

           } else {.

             $lc_text = '&nbsp;'$currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'&nbsp;';.

           }.

           break;.

         case 'PRODUCT_LIST_QUANTITY':.

           $lc_align = 'right';.

           $lc_text = '&nbsp;'$listing['products_quantity']'&nbsp;';.

           break;.

         case 'PRODUCT_LIST_WEIGHT':.

           $lc_align = 'right';.

           $lc_text = '&nbsp;'$listing['products_weight']'&nbsp;';.

           break;.

         case 'PRODUCT_LIST_IMAGE':.

           $lc_align = 'center';.

           if (isset($HTTP_GET_VARS['manufacturers_id'])) {.

             $lc_text = '<a href="'tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id='$HTTP_GET_VARS['manufacturers_id']'&products_id='$listing['products_id'])'">'tep_image(DIR_WS_IMAGES$listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)'</a>';.

           } else {.

             $lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath='$cPath'&' : '')'products_id='$listing['products_id'])'">'tep_image(DIR_WS_IMAGES$listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)'</a>&nbsp;';.

           }.

           break;.

         case 'PRODUCT_LIST_BUY_NOW':.

           $lc_align = 'center';.

           $lc_text = '<a href="'tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action'))'action=buy_now&products_id='$listing['products_id'])'">'tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW)'</a>&nbsp;<br><br>';.

           break;.

       }.

       $product_contents[] = $lc_text;.

     }.

     $lc_text = implode('<br>', $product_contents);.

     $list_box_contents[$row][$column] = array('align' => 'center',.

                                               'params' => 'class="productListing-data" valign="bottom"',.

                                               'text'  => $lc_text);.

     $column ++;.

     if ($column >= 3) {.

       $row ++;.

       $column = 0;.

     }.

   }.

   new productListingBox($list_box_contents);.

 } else {.

   $list_box_contents = array();.

   $list_box_contents[0] = array('params' => 'class="productListing-odd"');.

   $list_box_contents[0][] = array('params' => 'class="productListing-data"',.

                                  'text' => TEXT_NO_PRODUCTS);.

   new productListingBox($list_box_contents);.

 }.

 if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {.

?>.

<table border="0" width="100%" cellspacing="0" cellpadding="2">.

 <tr>.

   <td class="smallText"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></td>.

   <td class="smallText" align="right"><?php echo TEXT_RESULT_PAGE' '$listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></td>.

 </tr>.

</table>.

<?php.

 }.

?>.

HTH,.

Tony..

Comment #7

I have copied and pasted your code and I still have the same message :.

Fatal error: Cannot pass parameter 3 by reference in C:Inetpubwwwrootstorecatalogincludesmodulesproduct_listing.php on line 13.

I think it's got to do with something :.

LINE 13 = $listing_split = new splitPageResults($listing_sql, MAX_DISPLAY_SEARCH_RESULTS, 'p.products_id');.

'p.products_id' do I need to define this anywhere?..

Comment #8

Tony not sure if this helps but here is my old Product_listing code..

<?php.

/*.

$Id: product_listing.php,v 1.41 2003/02/12 23:55:58 hpdl Exp $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright © 2003 osCommerce.

Released under the GNU General Public License.

*/.

?>.

<table border="0" width="100%" cellspacing="0" cellpadding="2">.

<?php.

$listing_numrows_sql = $listing_sql;.

$listing_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_SEARCH_RESULTS, $listing_sql, $listing_numrows);.

// fix counted products.

$listing_numrows = tep_db_query($listing_numrows_sql);.

$listing_numrows = tep_db_num_rows($listing_numrows);.

If ( ($listing_numrows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) {.

?>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr>.

<td class="smallText">&nbsp;<?php echo $listing_split->display_count($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?>&nbsp;</td>.

<td align="right" class="smallText">&nbsp;<?php echo TEXT_RESULT_PAGE; ?> <?php echo $listing_split->display_links($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?>&nbsp;</td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator(); ?></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td>.

<?php.

$list_box_contents = array();.

$list_box_contents[] = array('params' => 'class="productListing-heading"');.

$cur_row = sizeof($list_box_contents) - 1;.

For ($col=0, $n=sizeof($column_list); $col<$n; $col++) {.

Switch ($column_list[$col]) {.

Case 'PRODUCT_LIST_MODEL':.

$lc_text = TABLE_HEADING_MODEL;.

$lc_align = '';.

Break;.

Case 'PRODUCT_LIST_NAME':.

$lc_text = TABLE_HEADING_PRODUCTS;.

$lc_align = '';.

Break;.

Case 'PRODUCT_LIST_MANUFACTURER':.

$lc_text = TABLE_HEADING_MANUFACTURER;.

$lc_align = '';.

Break;.

Case 'PRODUCT_LIST_PRICE':.

$lc_text = TABLE_HEADING_PRICE;.

$lc_align = 'right';.

Break;.

Case 'PRODUCT_LIST_QUANTITY':.

$lc_text = TABLE_HEADING_QUANTITY;.

$lc_align = 'right';.

Break;.

Case 'PRODUCT_LIST_WEIGHT':.

$lc_text = TABLE_HEADING_WEIGHT;.

$lc_align = 'right';.

Break;.

Case 'PRODUCT_LIST_IMAGE':.

$lc_text = TABLE_HEADING_IMAGE;.

$lc_align = 'center';.

Break;.

Case 'PRODUCT_LIST_BUY_NOW':.

$lc_text = TABLE_HEADING_BUY_NOW;.

$lc_align = 'center';.

Break;.

}.

If ( ($column_list[$col] != 'PRODUCT_LIST_BUY_NOW') && ($column_list[$col] != 'PRODUCT_LIST_IMAGE') ) {.

$lc_text = tep_create_sort_heading($HTTP_GET_VARS['sort'], $col+1, $lc_text);.

}.

$list_box_contents[$cur_row][] = array('align' => $lc_align,.

'params' => 'class="productListing-heading"',.

'text' => '&nbsp;'$lc_text'&nbsp;');.

}.

If ($listing_numrows > 0) {.

$number_of_products = '0';.

$listing_query = tep_db_query($listing_sql);.

While ($listing = tep_db_fetch_array($listing_query)) {.

$number_of_products++;.

If (($number_of_products/2) == floor($number_of_products/2)) {.

$list_box_contents[] = array('params' => 'class="productListing-even"');.

} else {.

$list_box_contents[] = array('params' => 'class="productListing-odd"');.

}.

$cur_row = sizeof($list_box_contents) - 1;.

For ($col=0, $n=sizeof($column_list); $col<$n; $col++) {.

$lc_align = '';.

Switch ($column_list[$col]) {.

Case 'PRODUCT_LIST_MODEL':.

$lc_align = '';.

$lc_text = '&nbsp;'$listing['products_model']'&nbsp;';.

Break;.

Case 'PRODUCT_LIST_NAME':.

$lc_align = '';.

If (isset($HTTP_GET_VARS['manufacturers_id'])) {.

$lc_text = '<a href="'tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id='$HTTP_GET_VARS['manufacturers_id']'&products_id='$listing['products_id'])'">'$listing['products_name']'</a>';.

} else {.

$lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath='$cPath'&' : '')'products_id='$listing['products_id'])'">'$listing['products_name']'</a>&nbsp;';.

}.

Break;.

Case 'PRODUCT_LIST_MANUFACTURER':.

$lc_align = '';.

$lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_DEFAULT, 'manufacturers_id='$listing['manufacturers_id'])'">'$listing['manufacturers_name']'</a>&nbsp;';.

Break;.

Case 'PRODUCT_LIST_PRICE':.

$lc_align = 'right';.

If (tep_not_null($listing['specials_new_products_price'])) {.

$lc_text = '&nbsp;<s>'$currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'</s>&nbsp;&nbsp;<span class="productSpecialPrice">'$currencies->display_price($listing['specials_new_products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'</span>&nbsp;';.

} else {.

$lc_text = '&nbsp;'$currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'&nbsp;';.

}.

Break;.

Case 'PRODUCT_LIST_QUANTITY':.

$lc_align = 'right';.

$lc_text = '&nbsp;'$listing['products_quantity']'&nbsp;';.

Break;.

Case 'PRODUCT_LIST_WEIGHT':.

$lc_align = 'right';.

$lc_text = '&nbsp;'$listing['products_weight']'&nbsp;';.

Break;.

Case 'PRODUCT_LIST_IMAGE':.

$lc_align = 'center';.

If (isset($HTTP_GET_VARS['manufacturers_id'])) {.

$lc_text = '<a href="'tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id='$HTTP_GET_VARS['manufacturers_id']'&products_id='$listing['products_id'])'">'tep_image(DIR_WS_IMAGES$listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)'</a>';.

} else {.

$lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath='$cPath'&' : '')'products_id='$listing['products_id'])'">'tep_image(DIR_WS_IMAGES$listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)'</a>&nbsp;';.

}.

Break;.

Case 'PRODUCT_LIST_BUY_NOW':.

$lc_align = 'center';.

$lc_text = '<a href="'tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action'))'action=buy_now&products_id='$listing['products_id'])'">'tep_image_button('button_buy_now.gif', TEXT_BUY$listing['products_name']TEXT_NOW)'</a>&nbsp;';.

Break;.

}.

$list_box_contents[$cur_row][] = array('align' => $lc_align,.

'params' => 'class="productListing-data"',.

'text' => $lc_text);.

}.

}.

New tableBox($list_box_contents, true);.

Echo ' </td>'"n" ..

' </tr>'"n";.

} else {.

?>.

<tr class="productListing-odd">.

<td class="smallText">&nbsp;<?php echo (isset($HTTP_GET_VARS['manufacturers_id']) ? TEXT_NO_PRODUCTS2 : TEXT_NO_PRODUCTS); ?>&nbsp;</td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td><?php echo tep_draw_separator(); ?></td>.

</tr>.

<?php.

If ( ($listing_numrows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {.

?>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr>.

<td class="smallText">&nbsp;<?php echo $listing_split->display_count($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?>&nbsp;</td>.

<td align="right" class="smallText">&nbsp;<?php echo TEXT_RESULT_PAGE; ?> <?php echo $listing_split->display_links($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?>&nbsp;</td>.

</tr>.

</table></td>.

</tr>.

<?php.

}.

?>.

</table>..

Comment #9

Hi I am still stuck with this one anyone there who can assist me Please...

Comment #10

I had the exact sam problem as posted earlier:.

Fatal error: Cannot pass parameter 3 by reference in \catalog\includes\modules\product_listing.php on line 13.

The last posted file of products_listning.php solved my problem right away..

Just copy this code into a new file saved as products_listing.php ( backup original first! ).

So I recommend you to try this code in.

Products_listing.php.

:.

<?php.

/*.

$Id: product_listing.php,v 1.41 2003/02/12 23:55:58 hpdl Exp $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright 2003 osCommerce.

Released under the GNU General Public License.

*/.

?>.

<table border="0" width="100%" cellspacing="0" cellpadding="2">.

<?php.

$listing_numrows_sql = $listing_sql;.

$listing_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_SEARCH_RESULTS, $listing_sql, $listing_numrows);.

// fix counted products.

$listing_numrows = tep_db_query($listing_numrows_sql);.

$listing_numrows = tep_db_num_rows($listing_numrows);.

If ( ($listing_numrows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) {.

?>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr>.

<td class="smallText">&nbsp;<?php echo $listing_split->display_count($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?>&nbsp;</td>.

<td align="right" class="smallText">&nbsp;<?php echo TEXT_RESULT_PAGE; ?> <?php echo $listing_split->display_links($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?>&nbsp;</td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator(); ?></td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td>.

<?php.

$list_box_contents = array();.

$list_box_contents[] = array('params' => 'class="productListing-heading"');.

$cur_row = sizeof($list_box_contents) - 1;.

For ($col=0, $n=sizeof($column_list); $col<$n; $col++) {.

Switch ($column_list[$col]) {.

Case 'PRODUCT_LIST_MODEL':.

$lc_text = TABLE_HEADING_MODEL;.

$lc_align = '';.

Break;.

Case 'PRODUCT_LIST_NAME':.

$lc_text = TABLE_HEADING_PRODUCTS;.

$lc_align = '';.

Break;.

Case 'PRODUCT_LIST_MANUFACTURER':.

$lc_text = TABLE_HEADING_MANUFACTURER;.

$lc_align = '';.

Break;.

Case 'PRODUCT_LIST_PRICE':.

$lc_text = TABLE_HEADING_PRICE;.

$lc_align = 'right';.

Break;.

Case 'PRODUCT_LIST_QUANTITY':.

$lc_text = TABLE_HEADING_QUANTITY;.

$lc_align = 'right';.

Break;.

Case 'PRODUCT_LIST_WEIGHT':.

$lc_text = TABLE_HEADING_WEIGHT;.

$lc_align = 'right';.

Break;.

Case 'PRODUCT_LIST_IMAGE':.

$lc_text = TABLE_HEADING_IMAGE;.

$lc_align = 'center';.

Break;.

Case 'PRODUCT_LIST_BUY_NOW':.

$lc_text = TABLE_HEADING_BUY_NOW;.

$lc_align = 'center';.

Break;.

}.

If ( ($column_list[$col] != 'PRODUCT_LIST_BUY_NOW') && ($column_list[$col] != 'PRODUCT_LIST_IMAGE') ) {.

$lc_text = tep_create_sort_heading($HTTP_GET_VARS['sort'], $col+1, $lc_text);.

}.

$list_box_contents[$cur_row][] = array('align' => $lc_align,.

'params' => 'class="productListing-heading"',.

'text' => '&nbsp;'$lc_text'&nbsp;');.

}.

If ($listing_numrows > 0) {.

$number_of_products = '0';.

$listing_query = tep_db_query($listing_sql);.

While ($listing = tep_db_fetch_array($listing_query)) {.

$number_of_products++;.

If (($number_of_products/2) == floor($number_of_products/2)) {.

$list_box_contents[] = array('params' => 'class="productListing-even"');.

} else {.

$list_box_contents[] = array('params' => 'class="productListing-odd"');.

}.

$cur_row = sizeof($list_box_contents) - 1;.

For ($col=0, $n=sizeof($column_list); $col<$n; $col++) {.

$lc_align = '';.

Switch ($column_list[$col]) {.

Case 'PRODUCT_LIST_MODEL':.

$lc_align = '';.

$lc_text = '&nbsp;'$listing['products_model']'&nbsp;';.

Break;.

Case 'PRODUCT_LIST_NAME':.

$lc_align = '';.

If (isset($HTTP_GET_VARS['manufacturers_id'])) {.

$lc_text = '<a href="'tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id='$HTTP_GET_VARS['manufacturers_id']'&products_id='$listing['products_id'])'">'$listing['products_name']'</a>';.

} else {.

$lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath='$cPath'&' : '')'products_id='$listing['products_id'])'">'$listing['products_name']'</a>&nbsp;';.

}.

Break;.

Case 'PRODUCT_LIST_MANUFACTURER':.

$lc_align = '';.

$lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_DEFAULT, 'manufacturers_id='$listing['manufacturers_id'])'">'$listing['manufacturers_name']'</a>&nbsp;';.

Break;.

Case 'PRODUCT_LIST_PRICE':.

$lc_align = 'right';.

If (tep_not_null($listing['specials_new_products_price'])) {.

$lc_text = '&nbsp;<s>'$currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'</s>&nbsp;&nbsp;<span class="productSpecialPrice">'$currencies->display_price($listing['specials_new_products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'</span>&nbsp;';.

} else {.

$lc_text = '&nbsp;'$currencies->display_price($listing['products_price'], tep_get_tax_rate($listing['products_tax_class_id']))'&nbsp;';.

}.

Break;.

Case 'PRODUCT_LIST_QUANTITY':.

$lc_align = 'right';.

$lc_text = '&nbsp;'$listing['products_quantity']'&nbsp;';.

Break;.

Case 'PRODUCT_LIST_WEIGHT':.

$lc_align = 'right';.

$lc_text = '&nbsp;'$listing['products_weight']'&nbsp;';.

Break;.

Case 'PRODUCT_LIST_IMAGE':.

$lc_align = 'center';.

If (isset($HTTP_GET_VARS['manufacturers_id'])) {.

$lc_text = '<a href="'tep_href_link(FILENAME_PRODUCT_INFO, 'manufacturers_id='$HTTP_GET_VARS['manufacturers_id']'&products_id='$listing['products_id'])'">'tep_image(DIR_WS_IMAGES$listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)'</a>';.

} else {.

$lc_text = '&nbsp;<a href="'tep_href_link(FILENAME_PRODUCT_INFO, ($cPath ? 'cPath='$cPath'&' : '')'products_id='$listing['products_id'])'">'tep_image(DIR_WS_IMAGES$listing['products_image'], $listing['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT)'</a>&nbsp;';.

}.

Break;.

Case 'PRODUCT_LIST_BUY_NOW':.

$lc_align = 'center';.

$lc_text = '<a href="'tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action'))'action=buy_now&products_id='$listing['products_id'])'">'tep_image_button('button_buy_now.gif', TEXT_BUY$listing['products_name']TEXT_NOW)'</a>&nbsp;';.

Break;.

}.

$list_box_contents[$cur_row][] = array('align' => $lc_align,.

'params' => 'class="productListing-data"',.

'text' => $lc_text);.

}.

}.

New tableBox($list_box_contents, true);.

Echo ' </td>'"\n" ..

' </tr>'"\n";.

} else {.

?>.

<tr class="productListing-odd">.

<td class="smallText">&nbsp;<?php echo (isset($HTTP_GET_VARS['manufacturers_id']) ? TEXT_NO_PRODUCTS2 : TEXT_NO_PRODUCTS); ?>&nbsp;</td>.

</tr>.

<?php.

}.

?>.

<tr>.

<td><?php echo tep_draw_separator(); ?></td>.

</tr>.

<?php.

If ( ($listing_numrows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {.

?>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="2">.

<tr>.

<td class="smallText">&nbsp;<?php echo $listing_split->display_count($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, $HTTP_GET_VARS['page'], TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?>&nbsp;</td>.

<td align="right" class="smallText">&nbsp;<?php echo TEXT_RESULT_PAGE; ?> <?php echo $listing_split->display_links($listing_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $HTTP_GET_VARS['page'], tep_get_all_get_params(array('page', 'info', 'x', 'y'))); ?>&nbsp;</td>.

</tr>.

</table></td>.

</tr>.

<?php.

}.

?>.

</table>..

Comment #11

Has anyone had this problem....

I have categories and sub categories, Some catergries when clicked it shows the default page with the sub categories with it's pictures and also Products for that month. BUT I have some categories that when click it just shows the list of all the products and not the sub categories.....

Any Idea's need help please.

Thanks. :cry:..

Comment #12

This is a standard part of osCommerce..

If a category has products under it, than no sub-categories are displayed. If a category has no products under it, than the sub-categories are displayed..

There is a contribution to show the sub-categories and the products at the same time. It can be found here:.

Http://www.oscommerc...tributions,1014.

I use this contribution on my site. You can see the effects of it here:.

Http://www.turningba...ex.php?cPath=21.

Cheers,.

Tony..

Comment #13


This question was taken from a support group/message board and re-posted here so others can learn from it.