I'm going to help you out and do it for you this one time as you seem very determined. Now you'll have a better understanding of the script as well!
replace line 85 with:
PHP Code:
$products_query = "SELECT p.products_id, p.products_model, pd.products_name, pd.products_description, p.products_image, p.products_tax_class_id, p.products_price_sorter, p.products_upc, p.products_isbn, s.specials_new_products_price, s.expires_date, GREATEST(p.products_date_added, p.products_last_modified, p.products_date_available) AS base_date, m.manufacturers_name, p.products_quantity, pt.type_handler, p.products_weight
You'll notice all I did was add the products_weight, found in TABLE PRODUCTS denoted with the (p.). Now you just need to create the outputs of
PHP Code:
$output["weight"] = "weight";
and
PHP Code:
$output["weight"] = products->fields['products_weight'];
They will need to be placed in the same order on both the titles and the column outputs. I recommend you add this to v1.5.1 instead and have it output the weight in XML format by just copying any of the other lines and using the appropriate google base attribute name such as <g:weight> (not sure if that is correct, you'll have to check in base.google.com). If so, all you'll need to add is this:
PHP Code:
$content["weight"] = '<g:weight>' . $products->fields['products_weight'] . '</g:weight>';
I would put this under line 146.
Side Note:
I am no longer going to support versions previous to the XML version 1.5.0. I have changed to this format for a reason due to future issues with google base. Older versions such as 1.3.3 are very outdated and do not include most of the required attributes unless you have heavily edited this version as woodymon did. In which case, it is no longer version 1.3.3 but some variant that he created himself. The UPC/ISBN is required and will eventually be used by Google to automatically include information about the product by using the stored attributes for that UPC/ISBN.
All illegal characters should now be removed and all of your products should validate and be accepted. Once again, if this is not the case, please post here and I will try to remedy the issue.
Bookmarks