Add Product and Update Product not working
Hi Jason,
On admin/products_update.php and admin/products_insert.php when push on Update or Insert buttons nothin happens, suppose something wrong in php code. May you help to find this bug??
Hi Jason,
On admin/products_update.php and admin/products_insert.php when push on Update or Insert buttons nothin happens, suppose something wrong in php code. May you help to find this bug??
Sure we can help... please post a url to view the page, any admin credentials necessary to reproduce the problem, and ftp details so we can debug and fix it. Make sure to include sensitive information like usernames and passwords in the private area so that only we can see them.
Further info when insert the price the validation show message "insert the price" or "Format not valid".
It wasn't passing the server validation because of the switched decimal format to using commas.
I resolved this by updating the server validation on line 179 from ",." to ".,".
That makes it get by the number validation, but it still doesn't store the value properly in the database... You may be able to resolve that by changing the number format settings in the database itself. If that doesn't work, then you can do a quick replace to put it back into US number format in the php before doing the database update.
I have update the Insert page with same code, but in the MySql db the price is declared as VARCHAR is correct??? Now not store correctly the number with comma eg: 10,56 store only 10 no decimal value are stored in db why???
It looks like your database has been updated and that column is set to have zero decimal places... I checked and the column type for the product price field is set to decimal(5,0) which means zero places after the decimal. You'll have to update your database to allow decimal places in the price column.
Thank you Ray, I have update the db field from VARCHAR to DECIMAL (5,2) and store now the decimal numbers but not with comma use always the dot why?? Then if I use a digital file [downloadable file photo in my case] and select the image product and choose the file on server the Update button seems not work (for try i have inserted the image flower), in the Product Results list the product is visible but not available for download if purchase it, another suggestion for this case???
I think mysql always stores numers with dots and not commas.... that is because the SQL syntax which uses commas to separate values in sql statements require numbers to never have commas in them. You would have to reformat the number whenever displaying it using the number_format() function.
I'll investigate why the file upload doesn't work.
It appears to work for me... maybe it was because the number validation was failing since it had a period instead of a comma.
I updated the price with the number_format() function for your reference.
Ray the last info what was wrong for upload file ???And thank you for support me until now.
Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.
These out-of-the-box solutions provide you proven, tested applications that can be up and running now. Build a store, a gallery, or a web-based email solution.