Jump to content
Latest News: (loading..)

Search the Community

Showing results for tags 'sort'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • News and Announcements
    • News and Announcements
    • Partner Announcements
    • Ambassadors
  • Commercial Support
    • Developer Feedback
  • osCommerce Online Merchant v2.x
    • General Support
    • Installation and Configuration
    • Upgrading from Earlier Versions (v2.x to v2.x)
    • Add-Ons
    • Tips and Tricks
    • Security
  • Development
    • osCommerce Online Merchant v2.4
    • osCommerce Online Merchant Community Bootstrap Edition
    • osCommerce Online Merchant v3.x
    • Development Proposals
  • General
    • Next Steps / Optimizations / Marketing
    • Live Shop Reviews
    • E-Commerce Laws
    • General Discussions
    • PHP / SQL / Web Design
  • oscBooks and oscTemplates's Announcements
  • Mini Template System's Announcements
  • PayPal's Announcements
  • Sage Pay's Announcements
  • Solomono - new level osCommerce templates's Announcements

Found 7 results

  1. Hi Everyone! I know there have been many post and topics about product sorting and ordering... trust me I have read them all On this topic I do have a question that I am hoping someone can help me and the OsCommerce Community with... How can I by default display products in the following sort / order: First: In Stock Products ( Products with Quantity Available Greater Than 0 ) Descending in Price ( from High to Low )... Then: Out Of Stock Products ( Products with Quantity Available Less Than And/Or Equal To 0 ) Descending in Price ( from High to Low )... I know this need to be done in index.php... I would appreciate help with the exact syntax and .php code need to make this happen. Thank you all for your help!
  2. This thread is about having a products sorting possibility like Sort by: Products A-Z Products Z-A Price High > Low Price Low < High Bestseller Latest added and maybe few other... I think this topic deserve it's own thread and I see that @@vampirehunter is very interested in getting this to work and so am I. If anyone has something like this working properly with osC please share your work here. Or if you have any ideas as to how approach this please share. Here is what I found a while back somewhere here in the forum. And I use this in my current non-BS shop but it is not coded properly and it requires at least 2 different manufacturers to be assigned to 2 products from the same category to make this filter work...stupid right? And you have to hard code the numbers and assign the text to each one of them. So here is my code if (isset($HTTP_GET_VARS['manufacturers_id']) && !empty($HTTP_GET_VARS['manufacturers_id'])) { $filterlist_sql = "select distinct c.categories_id as id, cd.categories_name as name from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where p.products_status = '1' and p.products_id = p2c.products_id and p2c.categories_id = c.categories_id and p2c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' and p.manufacturers_id = '" . (int)$HTTP_GET_VARS['manufacturers_id'] . "' order by cd.categories_name"; } else { $filterlist_sql = "select distinct m.manufacturers_id as id, m.manufacturers_name as name from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c, " . TABLE_MANUFACTURERS . " m where p.products_status = '1' and p.manufacturers_id = m.manufacturers_id and p.products_id = p2c.products_id and p2c.categories_id = '" . (int)$current_category_id . "' order by m.manufacturers_name"; } $filterlist_query = tep_db_query($filterlist_sql); if (tep_db_num_rows($filterlist_query) > 1) { echo '<div class="filter2">' . tep_draw_form('sort', FILENAME_DEFAULT, 'get') . TEXT_SORT; if (isset($HTTP_GET_VARS['manufacturers_id']) && !empty($HTTP_GET_VARS['manufacturers_id'])) { echo tep_draw_hidden_field('manufacturers_id', $HTTP_GET_VARS['manufacturers_id']); } else { echo tep_draw_hidden_field('cPath', $cPath); } $sort_list = array('2a' => SORT_NAME_A_Z, '2d' => SORT_NAME_Z_A, '3a' => SORT_PRICE_L_H, '3d' => SORT_PRICE_H_L); //'1a' => SORT_MODEL_A_Z, //'1d' => SORT_MODEL_Z_A); foreach($sort_list as $id=>$text) { $sort_range[] = array('id' => $id, 'text' => $text); } echo tep_draw_pull_down_menu('sort', $sort_range, (isset($HTTP_GET_VARS['sort']) ? $HTTP_GET_VARS['sort'] : ''), 'onchange="this.form.submit()"'); echo tep_draw_hidden_field('filter_id', (isset($HTTP_GET_VARS['filter_id']) ? $HTTP_GET_VARS['filter_id'] : '')); echo '</form></div>' . "\n"; }
  3. It would be good to allow lists (of products, categories and so on) to be sorted by alphabetical order according to the language's specific rules.
  4. About This add-on is based on SimpleSuggest, adding a search suggestion to your OsCommerce search box, but it also records each customers' searched keywords and sort the result products order by popular search, or even simply show the result in term of popular keywords. It also gives the ability to search in multiple keywords using AND/OR. Options can be set in Admin and automatically install and deal with database. By setting search type 'products' and sort by 'products', it works just like SimpleSuggest, but you can also sort the resulting products by 'keywords' - it's searched count. Or simply put search type to 'keywords' so it works as a self-learn search engine which gives the pass searched keywords (make sure you have enough saved search keywords before turn this on) ScreenShot http://richardfu.net/wp-content/uploads/2013/10/screenshot_1_search_suggest.jpg Search suggestion using or and multiple words http://richardfu.net/wp-content/uploads/2013/10/screenshot_2_admin_configuration.jpg Admin configuration http://richardfu.net/wp-content/uploads/2013/10/screenshot_3_stats_report.jpg Stats keyword searched 2.2.x Add-on page 2.3.x Add-on page
  5. Hi, I installed the French language pack and the Boxes configuration reverts to default when I switch to the second language (French). I am installing v2.3.3 and migrating changes from a 2.2a site. Most of the French content works (most is still from the module installation). The box content displays correctly, but the left/right configuration and the boxes displayed and sort order appear to be the system defaults. When installing the French module as an unzip from catalog, I chose not to overwrite as I did not want to have administrative functions in French. I even tried switching the language to French, going to the admin page and re-writing the boxes configuration, but no change. Searched all over the forums, but have not found the solution. Your help is greatly appreciated!
  6. Hello, I've trying to sort on product name with this script. But everything i try the output always is sort on order number and i want to sort on product name. Please can anyone rewrite this script so the output is sort on product name? Thanks in advanced. <?php $orders_query = tep_db_query("SELECT * from " . TABLE_ORDERS . " WHERE (orders_status = '1' OR orders_status = '2')"); while($orders_rows = tep_db_fetch_array($orders_query)) { $products_query = tep_db_query("SELECT * FROM " . TABLE_ORDERS_PRODUCTS . " WHERE orders_id = '" . $orders_rows['orders_id'] . "' ORDER BY products_name"); while($products_rows = tep_db_fetch_array($products_query)) { $ordStatus_query = tep_db_query("SELECT * from " . TABLE_ORDERS_STATUS . " WHERE orders_status_id = '" . $orders_rows['orders_status'] . "' "); $ordStatus_rows = tep_db_fetch_array($ordStatus_query); echo "<tr>"; echo "<td class=dataTableContent>" . $ordStatus_rows["orders_status_name"] . "</td>"; echo "<td class=dataTableContent>" . $orders_rows["orders_id"] . "</td>"; echo "<td class=dataTableContent>" . $products_rows["products_quantity"] . "</td>"; echo "<td class=dataTableContent>" . $products_rows["products_name"] . "</td>"; echo "<td class=dataTableContent>" . $products_rows["products_price"] . "</td>"; echo "</tr>"; } } ?> Best regards, Martin
  7. Hello, I am sure this has been done, but I cannot find it anywhere. Is there a way to sort your product lists by the product attributes? This obviously works for sorting by price and by manufacturer, since those two options are included. But is it much more difficult to retrieve the product attributes and sort your lists by them? So for example, let's say I sell shoes and want to sort the list of all shoes to only filter out the ones that are black, and each of my products has an attribute defined as "color" with the value of "black", or "blue", etc... Any help would be greatly appreciated....