OSCommerce Product Manager for Windows
FS#336 - Add database low-level functions to server-side script
Attached to Project:
OSCommerce Product Manager
Opened by Mario A. Valdez-Ramirez (mvaldez) - Monday, 18 September 2006, 15:18 GMT
Last edited by Mario A. Valdez-Ramirez (mvaldez) - Monday, 09 July 2007, 06:05 GMT
Opened by Mario A. Valdez-Ramirez (mvaldez) - Monday, 18 September 2006, 15:18 GMT
Last edited by Mario A. Valdez-Ramirez (mvaldez) - Monday, 09 July 2007, 06:05 GMT
|
DetailsWhile testing for ZenCart, we found the following:
The problem with ZenCart is that the database functions of osCommerce (the tep_db_xxxx family of functions) have been replaced by an object called queryFactory. To support ZenCart I first need to check how much code I need to change in the server-side script. Then I could rewrite the code to support both plain osCommerce and ZenCart (and other variants). I think (but I'm not sure as I have not reviewed the ZC code) I need to create a queryFactory instance, then call its connect method (not the tep_db_connect function), then use Execute to do the SQL queries (not the tep_db_query function), and use the returning object (recordset-like?) from Execute to iterate thru the database records (with MoveNext). A partial solution would be to write the low-level database functions ourselves, so that the server-side script (oscpm1_upload.php) can use them if not available from the store scripts. We would call them only if not found from the scripts, working in a mode we would call "DB compat mode 1" or something like that (to be reported to the OSCPMWin application when checking capabilities and to the user when loaded directly by the browser). |
This task depends upon
This idea was derived form some user comments in the forums.