Release: Shop By Price Ver. 5.3.1
Requires CE Phoenix 1.0.8.2+
PHP 7.0 - 8.0
by @raiwa
info@phoenixcartaddons.com
www.phoenixcartaddons.com

All credit goes to the original developer: Matt Davies and all other contributers of previous versions
This version tested on Phoenix 1.0.7.9
This version is NOT backward compatible to previous Phoenix releases,
so be careful when installing it and don't forget to backup.

Changes in Shop By Price v5.3.1
- Fixed sql error when "Use fast Tax Query" is set to "false"
- tested with Phoenix 1.0.8.20
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v5.3.0
- Code updates to match actual core coding standards
- moved shop_by_price.php page to override template
- tested with Phoenix 1.0.8.11
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v5.2.2
- Minor code updates to match core coding standards
- tested under PHP 7.4
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v5.2.1
- fixed categories filter. Thanks to @discxpress for the report and testing
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v5.2
- updated for CE Phoenix 1.0.7.2+ +
- updated shop_by_price.php for templateable pages
- updated modules to abstract modules
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v5.1
- updated for CE Phoenix 1.0.4.x +
- removed deprecated product listing configurations
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v5.0
- updated for CE Phoenix 1.0.1.x
- Updated template naming and auto inclusion in box module
- Changed default price ranges to fit Phoenix demo products prices
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.8
- updated for 2.3.4.1. CE Frozen
- Updated template naming and auto inclusion in content modules
- Updated each function for PHP 7.2
- added in_stock, is_special and manufacturer_id to queries in shop_by_price.php for data tags support
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.7
- hardcoded paths
- box module range selection restyled
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.6
- Changed $HTTP_GET_VARS to $_GET in [catalog]/shop_by_price.php
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.5
- update class constructor name for PHP 7 compatibility
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.4
- Fixed undefined constant and variable errors.
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.3
- Added configuration setting to box and content module to switch queries from "faster" to "more compatible"
  for stores using complicate tax set-up.
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.2
- Function format0 moved to modules: no core changes in currencies class any more.
- Added support for optional decimal price ranges.
-------------------------------------------------------------------------------------------------------
Changes in Shop By Price v4.1
- Fix for using both modules, box module in list mode.
- Removed not needed align entry in header content modul.
-------------------------------------------------------------------------------------------------------
New Features in Shop By Price v4.0
- Shop by price box updated to 2.3.4 BS version.
- Added Shop by price header module for 2.3.4 BS.
- All configuration entries added to the modules
- Search in categories and manufactures added
- Multi currency support
- Price ranges entry for each currency added to the modules
- Show prices with tax query improved
- Language files cleaned up
- spanish and german language files added
- shop_by_price.php updated for 2.3.4 BS
- filenames and database table names hardcoded
- all sql installation queries included in the modules

-------------------------------------------------------------------------------------------------------
Release: Shop By Price for osc2.3.1, Ver. 3.0, on 1-Jan-2012
All credit goes to the original developer: Matt Davies.
This version tested on Oscommerce osc-2.3.1
This version is NOT backward compatible to previous osc2.x releases,
so be careful when installing it and don't forget to backup.

-------------------------------------------------------------------------------------------------------

New Features in Shop By Price v2.1
Fixed: Problem with "breadcrumb";
Fixed: Problem with of table header;
Added: Text for empty queries with information;
Added: Capacity for new ordinance of registers through click in the top of the columns;
Added: Translation for Portuguese of Brazil;

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

New Features in Shop By Price v2.2
Added: Translation for Germany (Thanks to Kornie);
Added: Prices are displayed in infobox with the respective currency,
       using "symbol_left" and "symbol_right" of TABLE_CURRENCIES (Thanks to Kornie for idea);
Added: PageHeading with information of range value;
Added: Conversion of values before the query,
       what it allows to show correct result independent of the currency standard.

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

New Features in Shop By Price v2.2.1
Fixed: Update Translation for Germany;
Modification for this contribution to work with osCommerce MS2.

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

New Features in Shop By Price v2.3
Fixed: prices ranges are now displayed with their real values and currencies in the infobox
when the currency is switched with the menu (if you selected yens, it was searching between 0 and 20 yens, which returns less likely any product).  the logic has been changed, making new range creation much easier

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

New Features in Shop By Price v2.3.1
Added 2 missing fields in the database query (line 118 of), preventing the ability to sort by product weight and product model when these options were displayed in the product list page.

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

New Features in Shop By Price v2.4
Added: Facility to switch between dropdown list and standard list style;
       Default setting is dropdown list - simple comment on one line of code required to switch.

xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

New Features in Shop By Price v2.5
Changed: changed the file to look more like the file "advanced_search_result.php" which should be clean.
Changed: As a result, the background image used (top right corner) is the same as advanced search, this was not necessary but I found it more logical than the one used for new products. Of course you can change it.
Added: As a result, shop by price now take into account the special prices
Added: Also as a result, if you are using the "display prices with tax" feature of osCommerce, this should also work well now.
Added: Support to make it work with the contribution: "Product Listing in Columns" (this can be removed)
Fix: The prices chosen should display correctly in the title (some people had problems with that).
Changed: The array $price_ranges_sql has been removed and has been replaced with 2 new arrays : $price_min and $price_max, this was necessary to fix the "display prices with tax" feature. As a result, it is not working as before. Prices "Under" X are now prices "Under OR EQUAL". The same goes for prices "Above". I didn NOT changed the translation as I'm not sure of how to translate and I don't think this is a big deal. Note that the value 0 is used to avoid limits. For example, a value of 0 in the $price_min means there is no minimum value for the price and 0 in the price_max means there is no maximum value.
Todo:
- I think an array of class instead of 3 array (price_min, price_max, price_ranges) would be better. At least, I'm sure something could be donne to clean it.
- There is no test to know if price_max is greater than price_min, this could be done

-------------------------------------------------------------------------------------------------------

Release: Shop By Price v2.5 (-GuiGui-)
All credit goes to the original developer: Matt Davies.
This version tested on Oscommerce osc-2.2rc2a
This version change the way the code of shop by price work,
so be careful when installing it and don't forget to backup.

======================================================================================================
Support

Support by @raiwa only for this version 4.0BS in the support thread

Support for this contribution can be found in the Shop by Price Support Thread at the osCommerce website (http://forums.oscommerce.com/index.php?showtopic=233750) Please note that support for this contribution is provided on a limited basis. It's not the author(s) responsibility to ensure the contribution works with other's that are installed nor to trouble shoot installation issues.

While every effort has been made to ensure this contribution is as bug free as possible, as with all osCommerce contributions, they are installed at your own risk.

-------------------------------------------------------------------------------------------------------


Installation
------------

1: upload the following new files:
- [catalog]/includes/languages/english/modules/boxes/bm_shop_by_price.php
- [catalog]/includes/languages/english/modules/content/header/cm_header_shop_by_price.php
- [catalog]/includes/languages/english/shop_by_price.php
- [catalog]/includes/languages/espanol/modules/boxes/bm_shop_by_price.php
- [catalog]/includes/languages/espanol/modules/content/header/cm_header_shop_by_price.php
- [catalog]/includes/languages/espanol/shop_by_price.php
- [catalog]/includes/languages/german/modules/boxes/bm_shop_by_price.php
- [catalog]/includes/languages/german/modules/content/header/cm_header_shop_by_price.php
- [catalog]/includes/languages/german/shop_by_price.php
- [catalog]/includes/modules/boxes/bm_shop_by_price.php
- [catalog]/includes/modules/boxes/templates/tpl_bm_shop_by_price.php
- [catalog]/includes/modules/content/header/cm_header_shop_by_price.php
- [catalog]/includes/modules/content/header/templates/tpl_cm_header_shop_by_price.php
- [catalog]/includes/shop_by_price.php
- [catalog]/templates/override/includes/pages/shop_by_price.php

Make sure you are using the "override" template and have it selected in:
Admin : Configuration : My Store : Template Selection
Otherwise you must copy the following file:
- templates/override/includes/pages/shop_by_price.php
TO:
o templates/YOUR SELECTED TEMPLATE/includes/pages/shop_by_price.php

-------------------------------------------------------------------------------------------------------
A. [Alternative] Install Shop By Price Box
3a: Activation of the box:

   In the Admin Interface:- Admin->Modules->Box->[select install]
   Then edit the [Shop By Price] box

3b: Changing Price Ranges
Price Range Steps separated by comma for each currency. Default:"10,20,30,50,100"

3c: Choose "Drop Down" or "List"

-------------------------------------------------------------------------------------------------------
B. [Alternative] Install Shop By Price Header Module
3a: Activation of the header module:

   In the Admin Interface:- Admin->Modules->Content->[select install] Shop By Price [header]
   Then edit the [Shop By Price] Header Module

3b: Changing Price Ranges
Price Range Steps separated by comma for each currency. Default:"10,20,30,50,100"

-------------------------------------------------------------------------------------------------------
IMPORTANT:  If you add a new currency to your store, remove the shop by price box and header content module.
Then add the new currency and reinstall the shop by price modules. Adjust the Price Ranges for your new currency.
-------------------------------------------------------------------------------------------------------

4: Troubleshooting

If you are using "show prices with tax" and you have a very complicate tax setup and get wrong range results,
change the setting in the box/content module:
Use fast Tax Query: set to "False"
NOTE: this change will slow down the queries, so use only if needed.

-------------------------------------------------------------------------------------------------------

5: Support thread is here;

   https://phoenixcart.org/forum/app.php/addons/free_addon/shop_by_price/support


-------------------------------------------------------------------------------------------------------

