mk_osc Posted May 16, 2014 Share Posted May 16, 2014 I'm trying to figure on how to exclude a certain category or categories from feed. I was looking through my settings and noticed this option define('OPTIONS_PRODUCT_TYPE', 'full'); //full means the full category path (i.e., hardware,printers), anything else, or blank, means just the products category (i.e., printers) However I'm not sure what exactly is this for. I've tried replacing 'full' with a sample category in my shop, but the feed still contains all products. So it seems, that this is probably not the feature I'm looking for. Basic question: Does this script has this functionality at all ? I'm selling books and everything was working great until now, where google decided against a certain category of books in my shop, so I need to exclude this category from the feed, but I've really no idea if this is possible. Any help in the right direction would be very much appreciated. Thanks in advance. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted May 17, 2014 Share Posted May 17, 2014 No, that ability is not in this version. It is in the next one but that is not ready for release yet. You will need to edit the sql code in the file to exclude whatever categories you don't want. I seem to recall someone asking this before but I don't know if any code was posted for it. You may want to go back through 5-10 pages to see if there is anything like that. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
mk_osc Posted May 17, 2014 Share Posted May 17, 2014 Hello, I've found a code on page 84 just insert after AND categories.categories_id=categories_description.categories_id " . $quotes . " lines like this, where 41 is the category to exclude AND categories.categories_id != '41' This seem to be working ok. However I'm not sure what I've to use for sub category. I've tried the following where 22 is the parent category and 24 the sub category AND categories.categories_id != '22' AND categories.categories_id != '24' I've also tried AND categories.categories_id != '22_24' but no luck. I've noticed that the number of products is reduced but when I check the export txt the items from the sub category are in the feed file. So I really don't know which items in which category were skipped. Strange. Any idea on how to correctly call the sub categorie along with the parent category, since the products are linked to both. Thanks again :) Quote Link to comment Share on other sites More sharing options...
mk_osc Posted May 17, 2014 Share Posted May 17, 2014 upon further review, I've noticed that the exclusion is only of cosmetic nature e.g. in the confirmation message Feed contains xxxxx products. File Completed: feedname.txt after creating the feed, the figure is obviously reflecting the exluded items in the excluded category, but in the feedname.txt it's not reflected. The products are included. hmmmm, any idea ? Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted May 18, 2014 Share Posted May 18, 2014 No, I'm sorry but I don't. I would have to go through the code to find the problem but I don't have the time for that right now. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
santosh0425 Posted June 27, 2014 Share Posted June 27, 2014 (edited) Please send me codes, so that I will check and try to rectify issue. Edited June 27, 2014 by santosh0425 Quote Link to comment Share on other sites More sharing options...
zpupster Posted July 3, 2014 Share Posted July 3, 2014 hello, i have been using this for sometime now. Google is giving me errors on my specials : Temporary item disapprovals due to incorrect prices i contacted them , they looked at one item and reparroved it, i could contact them again for the other items , but thoughti would check here to see if thei has happened to anyone else, and what they did to correct the problem. thanks, craig Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted July 3, 2014 Share Posted July 3, 2014 Did they give a reason for disapproving them? If no change is needed on your end then It is their fault and they should fix it. I suggest contacting them and asking that they reapprove all items or explain why they can't be. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
zpupster Posted July 3, 2014 Share Posted July 3, 2014 Thanks Jack, when i contacted google merchant. i thought all "special" items would be reapproved, when i checked back after the consersation-- they reparroved only one and disapproved other "special" products. i just wondered if they were doing this to all oscommerce sites with specials, i will call again and let you know how it turns out. craig Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted July 3, 2014 Share Posted July 3, 2014 None of my clients have mentioned it. But google have scripts and people to check the feeds. The check by people is done on far fewer sites since it takes so much longer. That might be what happened in your case. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
zpupster Posted July 10, 2014 Share Posted July 10, 2014 hello jack, i contacted google again. why my special products are being disapproved? they finally stated that i need a price field and a sales price field in the feed. i have updated to googlefeeder v 3.1 but i did not see a sales price field , however i did see that included in the google feeder next version( i think v3.2) for 2.3.4- had a sales price field. i have not updated our site yet to that version yet, i guess i will just try to borrow the code from v 3.2 for the sales price field and place that into v 3.1 until i update to oscommerce 2.3.4. i will let you know how it goes. thanks for everything, craig Quote Link to comment Share on other sites More sharing options...
Mtme Posted September 2, 2014 Share Posted September 2, 2014 As Jack, I did not know the account database. Now I understand ... Many thanks. When trying to make changes in step 7, I could not find the text; "mysqli_fetch_field function ($ query) { mysql_fetch_field return ($ query); } " The closest thing I've found is: "tep_db_fetch_fields function ($ db_query) { mysql_fetch_field return ($ db_query); } " And now I get the following error in the manager: "Fatal error: Can not redeclare mysqli_fetch_object () in / home / www / domainname.com / admin / includes / functions / database.php on line 130" And on the web; "Fatal error: Can not redeclare mysqli_fetch_object () in / home / www / domainname.com / includes / functions / database.php on line 126" I know nothing of progamación, I'm a rookie. . I do not know how to change those lines. Anyone have any ideas? Thanks consuelo I am having the same issue, function mysqli_fetch_field($query) { return mysql_fetch_field($query); } Does not exist in my database.php and I really do not understand the few posts about fixing this so the script will run. I have been spinning my wheels on this for many hours and i can't seem to figure it out given the little info on the board. If someone could be so kind to explain to me in as much detail as possible on what i need to change/modify to get this to run on 2.3 install that does not have the above function. thanks! Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted September 2, 2014 Share Posted September 2, 2014 @@Mtme The database code in oscommerce was changed from MySQL to mysqli in 2.3.3.2, as I recall. Whoever made the last few changes for this addon didn't bother to provide other versions (lazy), so you either need to use an older version or convert the code to the previous methods. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
davidkinsella Posted October 22, 2014 Share Posted October 22, 2014 Hi there, Been hunting around and in previous posts and saw talk about excluding products from the list. I saw that jack_mcs said that it would be in a later version. I have hunted around and cannot find the code. Was it ever released, and if not does anybody have a solution to exclude products from the output file without setting the quantity to 0 Quote Link to comment Share on other sites More sharing options...
mk_osc Posted October 22, 2014 Share Posted October 22, 2014 I'm not aware that it was included, I had completely removed my products from google and did not send any feed to them, since they don't like some of my products. Then recently I started again and sent a feed and the products were approved. 2 days ago, now another threat by google about account suspension if I continue to upload certain items to their server. Have you received also such an email, or do you just don't want to advertise all of your products ? Quote Link to comment Share on other sites More sharing options...
davidkinsella Posted October 22, 2014 Share Posted October 22, 2014 I just dont want to advertise all my products, but I have also had problems with the google police in the past! Quote Link to comment Share on other sites More sharing options...
Roaddoctor Posted October 22, 2014 Share Posted October 22, 2014 @@Jack_mcs Jack, What version is your latest version or which do you suggest? addons are confusing. Will it work with 2.3.4? Is it up to date with the latest feed specification requirements? https://support.google.com/merchants/answer/188494?hl=en Quote -Dave Link to comment Share on other sites More sharing options...
cmsideas Posted October 22, 2014 Share Posted October 22, 2014 Hi...Can all this (including the script) be put in a cron job? If so, can you please tell me the code to put in cron? Thank you, Quote Cmsideas.net is developing best class Magento Extensions base on an great team. OneStepCheckout | Magento Full Page Cache | Magento Mobile Theme | Magento Ajax Cart Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 22, 2014 Share Posted October 22, 2014 @@davidkinsella @@Roaddoctor - I'll be uploading a new version today or tomorrow so I suggest waiting until then. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 22, 2014 Share Posted October 22, 2014 @@cmsideas See the instructions regarding cron. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
davidkinsella Posted October 23, 2014 Share Posted October 23, 2014 @@Jack_mcs Thanks very much for the update. I cant wait to see it. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 23, 2014 Share Posted October 23, 2014 A new version has been uploaded with these changes: - Added an option to exclude products. Enter a comma separated list of product ID's and they will excluded from the feed.- Added an option to exclude categories. Enter a comma separated list of category ID's and the products in them will excluded from the feed.- Added identifier exists option. To be sure check the instructions on google to see if this is needed or not.- Changed code to be compatible with mysqli (oscommerce 2.3.4).- Changed code so the default language is read in automatically.- Changed the weight column to shipping weight for sites that use googles shipping option.- Changed column heading google product_category to google product category.- Corrected csv code provided by Richard (fur). Still not completely correct but is at least viewable now. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
mk_osc Posted October 23, 2014 Share Posted October 23, 2014 Hi Jack, I'm very grateful for the updated version :thumbsup: While testing it I'm running into an issue with the identifier exists option. identifier exists is set to 0 (i even tried 1) MPN and BRAND is also set to 0 as such, I believe your script should output a false to the identifier exists. Is that correct ? However, google complains, that my gtin is missing and in the feed, there is no setting entry for an identifier exists. hmm :unsure: any idea what might be wrong ? Thanks. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 23, 2014 Share Posted October 23, 2014 Only sites that seel certain products should use that option. If the identifier exists settings is set to 0, it is not used. If it is set to 1, the two of Brand, MPN and GTIN should be set. If they are and are empty, that column is set to false, meaning those entries do not exist. Since you don't have two of the required columns enabled, are you sure you need that setting? If you do and you run the feed, the identifier exists column for those products should be set to false. This is the rule from googles dos: Exception: in categories where unique product identifiers are required but no such identifier exists for an item (e.g. custom goods), submit 'identifier exists' with a value of FALSE. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
mk_osc Posted October 24, 2014 Share Posted October 24, 2014 Hi Jack, thanks for clarification, but the problem is, the identifier exists column is not generated for some reason. And yes, I need identifier exists column with the value false. These are my current settings, for which the identifier exists column should be generated and set to false. Is this correct? Or am I missing something. /*************** OPTIONS - IF ENABLED, ALSO SET THE SIMILAR OPTION FARTHER DOWN ******************/ define('OPTIONS_ENABLED', 1); define('OPTIONS_ENABLED_AGE_RANGE', 0); define('OPTIONS_ENABLED_ATTRIBUTES', 1); define('OPTIONS_ENABLED_BRAND', 0); //if set, see options for this setting below define('OPTIONS_ENABLED_CONDITION', 1); define('OPTIONS_ENABLED_CURRENCY', 1); define('OPTIONS_ENABLED_EXPIRATION', 1); define('OPTIONS_ENABLED_FEED_LANGUAGE', 0); define('OPTIONS_ENABLED_GTIN', 0); //if set, a database field named products_gtin must exist define('OPTIONS_ENABLED_GOOGLE_PRODUCT_CATEGORY', 1); //http://www.google.com/support/merchants/bin/answer.py?answer=160081 define('OPTIONS_ENABLED_GOOGLE_UTM', 1); define('OPTIONS_ENABLED_IDENTIFIER_EXISTS', 1); //set to 0 if required - https://support.google.com/merchants/answer/188494?hl=en define('OPTIONS_ENABLED_ISBN', 0); //if set, a database field named products_isbn must exist define('OPTIONS_ENABLED_MADE_IN', 0); define('OPTIONS_ENABLED_MPN', 0); //if set, see options for this setting below define('OPTIONS_ENABLED_PRODUCT_MODEL', 0); //displays the product model define('OPTIONS_ENABLED_PRODUCT_TYPE', 1); define('OPTIONS_ENABLED_SHIPPING', 0); define('OPTIONS_ENABLED_INCLUDE_TAX', 0); //0 = no tax, 1 = uses google method, 2 = UK Vat define('OPTIONS_ENABLED_UPC', 0); //if set, a database field named products_upc must exist define('OPTIONS_ENABLED_WEIGHT', 1); when I set define('OPTIONS_ENABLED_BRAND', 1); define('OPTIONS_ENABLED_MPN', 1); the identifier exists column is generated now with the value TRUE. But I can not get the opposite with FALSE, no matter what I do. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.