Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Change default product name to product model


freddyboy

Recommended Posts

if ( (!isset($HTTP_GET_VARS['sort'])) || (!preg_match('/^[1-8][ad]$/', $HTTP_GET_VARS['sort'])) || (substr($HTTP_GET_VARS['sort'], 0, 1) > sizeof($column_list)) ) {

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

if ($column_list[$i] == 'PRODUCT_LIST_MODEL') {

$HTTP_GET_VARS['sort'] = $i+1 . 'a';

$listing_sql .= " order by pd.products_model";

break;

}

}

 

 

HI All!!

 

I changed the above code in the index.php file so that the database would order the products by model instead of the default name.

 

It did not work however I followed the instructions here to the T http://www.oscommerce.com/forums/topic/308798-product-listing-sort-order/

Link to comment
Share on other sites

might be p.products_model

 

HTH

 

G

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

https://www.jaycarsales.com/Dbase/index.php?cPath=22_50_737

In this format the client wants also the model# to display. That is possible correct? I see the product number 1, 2, 3, 4, 5, 6, 7, are there in order however only when click on but I would like to see them also when the sizes are all displayed as the shown on the page link provided.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...