This version of the contribution should be fully compatible with osCommerce 2.2 RC2a and register globals (on or off). Other changes include (see the changelog for complete list):

1) Switched the minus to descending and the plus to ascending.

2) Updated Clear All to use * instead of 0 as the magic value.

3) Added tep_db_prepare_input and (int) casting when using int parameters with the DB.

Support thread: http://forums.oscommerce.com/index.php?showtopic=344632

More...