After playing with WP e-commerce for sometime and fixing some issues (see Incorrect URLs for images, css and js files in Products page of WP e-commerce plugin, Fix of Settings menu on WP e-commerce’s Products admin page and Tips on display categories in WP ecommerce), I am able to display products and categories. But I also notice an issue which is users can’t really update product details such as product name, description, product tags, and price and stock control after a product is added.
Let’s take a look at what the issue is. If you check your apache log for your site, then you will notice there is an error message regarding the update SQL query statement used to update the product details as shown below:
[Tue Jun 18 12:11:34 2008] [error] [client IP-ADDRESS] WordPress database error Incorrect integer value: '' for column 'brand' at row 1 for query UPDATE `wp_product_list` SET `name` = '9113 - Retractable ball pen', `description` = 'Plastic retractable ball pen', `additional_description` = '', `price` = '0.70', `pnp` = '', `international_pnp` = '5', `brand` = '', quantity_limited = '0', `quantity` = '0', `special`='0', `special_price`='', `display_frontpage`='0', `notax`='1', `donation`='0', `no_shipping` = '0' WHERE `id`='1' LIMIT 1 made by include, referer: http://blog.sdu2.hyperion.com/wp-admin/admin.php?page=wp-e-commerce/display-items.php
The error specifically points out that
database error Incorrect integer value: '' for column 'brand' Continue reading
“catagorylist” is not defined
I tried to find out a solution from WP e-commerce’s forum, unfortunately there is no one reporting this issue at all. So I am wondering that most of us are not using the latest version of the plugin, so I dig into the code and figure out the plugin is using the latest version of jQuery, I am documenting this here for myself’s later use just in case I forget it and also throw this out so that others can also benefit, so here is what I did to fix the issue: Continue reading