Irin Posted October 11, 2012 Share Posted October 11, 2012 Hi. Great add-on. I'm using the "Enable & Disable Categories" contribution and was wondering what do I need to change to force the sitemap to not display the hidden categories. Also, I want to display only manufacturers that have linked products and hide those that have no products. How can I do that? Thanks in advance. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 11, 2012 Author Share Posted October 11, 2012 I don't use that contribution so I don't know what code to add to limit the category. It would have to be added to the sitemap module files where categories are called. For the manufacturers, I think changing this line in includes/modules/sitemap_manufacturers.php file $products_query = tep_db_query("select m.manufacturers_id, m.manufacturers_name from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on p.manufacturers_id = m.manufacturers_id left join " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c on p2c.products_id = p.products_id left join " . TABLE_CATEGORIES . " c on p2c.categories_id = c.categories_id where p.products_status > 0 and c.categories_id = " . $mapCID); to $products_query = tep_db_query("select m.manufacturers_id, m.manufacturers_name from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on p.manufacturers_id = m.manufacturers_id left join " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c on p2c.products_id = p.products_id left join " . TABLE_CATEGORIES . " c on p2c.categories_id = c.categories_id where p.products_status > 0 and p.products_quantity > 0 and c.categories_id = " . $mapCID); Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Irin Posted October 11, 2012 Share Posted October 11, 2012 Hi Jack, I managed to disable the hidden categories by adding c.categories_status = '1' to the following query in category_tree.php and category_tree_no_products.php: $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.parent_id from " . TABLE_CATEGORIES . " c left join " . TABLE_CATEGORIES_DESCRIPTION . " cd on c.categories_id = cd.categories_id where c.categories_status = '1' and cd.language_id = '" . (int)$languages_id . "' order by c.parent_id, c.sort_order, cd.categories_name"); I changed the line like you suggested in includes/modules/sitemap_manufacturers.php and includes/modules/sitemap.php, but unfortunately it didn't change how the manufacturers are being displayed. Any other ideas? Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 11, 2012 Author Share Posted October 11, 2012 No, I only provide limited support for non-standard changes. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
blaine109 Posted October 25, 2012 Share Posted October 25, 2012 Jack, I get the following error when I go to sitemap.php Fatal error: Cannot redeclare in_multi_array() (previously declared in /home/****/public_html/includes/functions/general.php:1377) in /home/*****/public_html/includes/functions/sitemap.php on line 132 Thanks, Blaine Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 25, 2012 Author Share Posted October 25, 2012 In the includes/functions/sitemap.php and includes/modules/sitemap.php files, find in_multi_array and change it to something else, like sitemap_in_multi_array Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
blaine109 Posted October 25, 2012 Share Posted October 25, 2012 In the includes/functions/sitemap.php and includes/modules/sitemap.php files, find in_multi_array and change it to something else, like sitemap_in_multi_array Thank you sir. Quote Link to comment Share on other sites More sharing options...
blaine109 Posted October 25, 2012 Share Posted October 25, 2012 Jack, I am also looking for a contribution to generate a sitemap that I can submit to google, bing, etc. Is you Dynamic Sitemap contribution (http://addons.oscommerce.com/info/3306) still an active project of yours and does it work with all the other contributions (headertags, seo urls, etc.)? Thanks, Blaine Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted October 25, 2012 Author Share Posted October 25, 2012 No, I don't recommend the Dynamic Sitemap contribution. This one and the "Google XML Sitemap SEO" are better for the onsite and offsite site maps. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
blaine109 Posted October 26, 2012 Share Posted October 26, 2012 Does anyone else have issues with FireFox not showing the .css styles? They work properly in IE but firefox there is no formatting. Quote Link to comment Share on other sites More sharing options...
blaine109 Posted October 27, 2012 Share Posted October 27, 2012 Found another minor HTML issue in sitemap_manufacturers.php Change: echo '<tr><td width="10"> </td><td class="sitemap_indvidual">' . TEXT_NO_MANUFACTURERS_FOUND . '</td></tr>'; To: echo '<tr><td><table><tr><td width="10"> </td><td class="sitemap_indvidual">' . TEXT_NO_MANUFACTURERS_FOUND . '</td></tr></table></td></tr>'; The original code caused an HTML parsing error by putting too many table cells in a column that has only been taking 1 table cell per row. This error would only be seen if you had a product with no manufacturer set for a product. Quote Link to comment Share on other sites More sharing options...
blaine109 Posted October 27, 2012 Share Posted October 27, 2012 Another HTML change in sitemap_category.php Change: $mapCatStr = '<div> <tr> <td><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td class="sitemap_indvidual">' . $catname['cname'] . '</td> </tr> </table></td> </tr></div>'; To: $mapCatStr = '<div> <table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td class="sitemap_indvidual">' . $catname['cname'] . '</td> </tr> </table></div>'; Also, is anyone having issues with Firefox not picking up the css styles? All the colors are showing properly in IE9 but no styles are properly displaying in Firefox. Quote Link to comment Share on other sites More sharing options...
dewarsco2 Posted November 5, 2012 Share Posted November 5, 2012 Could there be a mistake in the install instructions or did I miss something. Installed on osC v2.3.3 and V2.3.1 Had to insert in includes/languages/english/modules/boxes/bm_information.php define('MODULE_BOXES_INFORMATION_SITEMAP_SEO', 'Site Map'); To get the information box to read "Site Map" Was this left out of the install instructions?? Or did I overlook something. Posted just in case others are having the same problem. Works perfect now. Thanks for a great contrib. Quote "Do what I'm thinking Not what I said." https:windowanddoorparts.us Link to comment Share on other sites More sharing options...
Jack_mcs Posted November 6, 2012 Author Share Posted November 6, 2012 I checked the latest version and that definition is present. Maybe you have an older version? Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
ruffryder007 Posted December 4, 2012 Share Posted December 4, 2012 Could there be a mistake in the install instructions or did I miss something. Installed on osC v2.3.3 and V2.3.1 Had to insert in includes/languages/english/modules/boxes/bm_information.php define('MODULE_BOXES_INFORMATION_SITEMAP_SEO', 'Site Map'); To get the information box to read "Site Map" Was this left out of the install instructions?? Or did I overlook something. Posted just in case others are having the same problem. Works perfect now. Thanks for a great contrib. Yup i just downloded and installed this, and same issue here... Thanks for pointing it out, cuz i was a little confused for a moment. Quote Link to comment Share on other sites More sharing options...
IWAS Posted December 29, 2012 Share Posted December 29, 2012 Jack, I Upgraded from 1.8 to 1.9. You originally did the install of SEO 1.7 and 1.8 (I believe.) I am running 2.2rcsomething. In order to upgrade it says just to replace the new files only. Did that. When you look at a product info page it shifts my product description taking up the entire description area and the area where column right goes, forcing column right to be on left side directly below column left. I restored the backup and it goes away. So just to make sure it wasn't other add-on updates that I have been doing, I upload the files again. Same result. It doesn't do it on any other pages other than productinfo pages. Any clue where to look? I restored it again and it is gone now. http://absolutelyscooterparts.net Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted December 30, 2012 Author Share Posted December 30, 2012 If you look at the history file you will see there were two changes made for appearance. One of those must be causing this problem. The changes would be one or more of the module files and the sitemap.php file. You could try replacing one of those at a time to find the problem. Or comparethem with the 1.8 files to see the difference. The appearance changes are not required for proper operation so you can skip those as long as you know that is all that was changed in the file. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Nexus1337 Posted January 10, 2013 Share Posted January 10, 2013 Hello ! I got two things installed in my oscommerce shop 2.3.3, sitemap seo and sitemap seo 5 pro. Both working fine unless there's one small thing: In the Sitemap itself the product links are working fine. So if you click on a product, the product page opens. But the main categories have wrong links. What can that be ? Here the url: http://dsc-electronics.com/sitemap.php Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 10, 2013 Author Share Posted January 10, 2013 This addon just uses the standard oscommerce link function. If the links are not formatted correctly, it has to be due to the url rewriter you are using. You can turr SEO 5 off to verify the links work correctly. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
Nexus1337 Posted January 10, 2013 Share Posted January 10, 2013 Just tested, it's not SEO 5. The problem still exists. Also, in the "menu" listing of the website the links are okay, only in the sitemap the links are broken. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 10, 2013 Author Share Posted January 10, 2013 Then there is something wrong with the link function in your site. This addon doesn't create any urls from its own code. It just uses the shops code to do that. There's no way to test this that I can think of, beyond what you've done so far, so I don't have any other suggestions for you. If you can't get it to work and wish to, then you would need to pay someone to look at the code. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
ggrant3 Posted February 9, 2013 Share Posted February 9, 2013 Jack, If I added some pages in the information box section and wanted them to show up in the Sitemap, how would I do that. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted February 10, 2013 Author Share Posted February 10, 2013 Go to box control and enable the Information box. Also be sure there is text for the box section in the settings. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons Link to comment Share on other sites More sharing options...
ggrant3 Posted February 11, 2013 Share Posted February 11, 2013 (edited) Would it matter if I am using Information Pages Unlimited? Because that is what I tried and I get errors. Also, the links don't match up with my pages (i.e shipping and privacy pages) Edited February 11, 2013 by ggrant3 Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted February 11, 2013 Author Share Posted February 11, 2013 Box Control only works with infoboxes with hard code links so that won't help you. But the code is built to handle those links. You have to enable it in the settings and it should load them. Quote Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons 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.