Jack_mcs Posted January 1, 2009 Share Posted January 1, 2009 (edited) This contribution fixes many of the deficiencies of the other sitemap contributions. It has been tested in MS2 and RC2 shops but should run in any variation of oscommerce. All settings are controlled via admin. It has the following following features. - Displays all pages and boxes - no missing links or text - Displays categories, with or without products - Displays manufacturers, with or without products - Links can be sorted - Links can be excluded - Links can be set to show for registered customers only - Sections of links can be sorted - Sections of links can be excluded - Sections of links can be set to show for registered customers only - All links have configurable anchor text - All links have configurable alternate display names - All sections of links can be placed anywhere on the sitemap page via admin - Supports Articles Manager Infopages Page Manager Jack Edited January 1, 2009 by Jack_mcs 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...
Guest Posted January 1, 2009 Share Posted January 1, 2009 Hi Jack Just trying this on my test server in wamp. I noticed that in the admin and catalog that the files in classes did not have the opening <?php it just had <? which is not a problem unless you have php5. Once installed, in admin ---> sitemap seo ---> box control I get Select a Box Note: This is a multi-select list so more than one item can be selected at once. Fatal error: Cannot use string offset as an array in E:\wamp\www\coopco.asrock\admin\includes\functions\sitemap.php on line 410 which has if ($selected_vals[$j]['id'] == $values[$i]['id']) Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 1, 2009 Author Share Posted January 1, 2009 Yes, you are correct about the <? in the category_tree files. Those were copied from earlier releases and I didn't notice they used that code. Thanks for pointing it out. Also, there aren't any class files used in admin so that can be deleted from there. As for the multi-select, at line 406 in the admin/includes/functions/sitemap.php file, change else to else if (tep_not_null($selected_vals)) . I think that will fix it but if not, please let me know and I will install it into a php 5 shop. Jack 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...
Guest Posted January 1, 2009 Share Posted January 1, 2009 Yes, you are correct about the <? in the category_tree files. Those were copied from earlier releases and I didn't notice they used that code. Thanks for pointing it out. Also, there aren't any class files used in admin so that can be deleted from there. As for the multi-select, at line 406 in the admin/includes/functions/sitemap.php file, change else to else if (tep_not_null($selected_vals)) . I think that will fix it but if not, please let me know and I will install it into a php 5 shop. Jack Hi Jack Thank you for your quick response and remedy. The new code fixed it and the Boxes Group Control page now displays correctly and error free. Will install in live site tomorrow. BTW, the contribution is fantastic and the display of the site map is even better. Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 1, 2009 Author Share Posted January 1, 2009 Thanks. I appreciate the feedback. :) Jack 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...
bkellum Posted January 1, 2009 Share Posted January 1, 2009 Jack, This is awesome and a must! I will be installing this right-away! :rolleyes: Thanks for the add-on. Quote Bill Kellum Sounds Good Productions STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 1, 2009 Author Share Posted January 1, 2009 Thanks. I'm pleased with how it turned out. Although I didn't think to test it in STS. I'll keep my fingers crossed. :) Jack 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...
bkellum Posted January 1, 2009 Share Posted January 1, 2009 (edited) Thanks. I'm pleased with how it turned out. Although I didn't think to test it in STS. I'll keep my fingers crossed. :) Jack No problems so far regarding STS. STS users can also template the sitemap page by creating a template called sitemap.php.html. One issue that I am working out has to do with the Page Editor contribution (http://www.oscommerce.com/community/contributions,2841). Minor issues that have to do with that contribution and not Sitemap Seo. Page Editor creates links very similar to Page Manager but uses the pages_id instead of the pages_title. Edited January 1, 2009 by bkellum Quote Bill Kellum Sounds Good Productions STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE Link to comment Share on other sites More sharing options...
Guest Posted January 2, 2009 Share Posted January 2, 2009 Thanks. I appreciate the feedback. :) Jack Hi Jack I wonder if it is possible for the field for alt text and anchor text could remain updated. If I make one change, then update, make another change, then update, I lose the previous change. Quote Link to comment Share on other sites More sharing options...
♥14steve14 Posted January 2, 2009 Share Posted January 2, 2009 Jack Installed this today, and apart from the error mentioned at the top of this page it all works fine. It looks good, but will have to take time out and find out what everything does. Great contribution. Quote REMEMBER BACKUP, BACKUP AND BACKUP Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 2, 2009 Author Share Posted January 2, 2009 Hi Jack I wonder if it is possible for the field for alt text and anchor text could remain updated. If I make one change, then update, make another change, then update, I lose the previous change. Wow, don't know how I missed that. I know I tested it at one point. Anyway, in admin/sietmap_seo_page_control.php, find this code at line 205 <td><input type="checkbox" name="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" id="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" <?php echo $pageSettings[$p]['excluded']; ?> maxlength="2" size="3"></td> <td width="22%"><?php echo $pagesArray[$id][$p]['filename']; ?></td> <td width="22%"><nobr><?php echo $pagesArray[$id][$p]['display_name']; ?></nobr></td> <td width="22%"><input type="text" name="<?php echo 'alternate_name_' . $id . '_' . $p; ?>" maxlength="255" size="24"></td> <td width="22%"><input type="text" name="<?php echo 'anchor_text_' . $id . '_' . $p; ?>" maxlength="255" size="24"></td> <td><input type="text" name="<?php echo 'sort_order_' . $id . '_' . $p; ?>" maxlength="2" size="3"></td> and change it to <td><input type="checkbox" name="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" <?php echo $pageSettings[$p]['excluded']; ?> id="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" <?php echo $pageSettings[$p]['excluded']; ?> maxlength="2" size="3"></td> <td width="22%"><?php echo $pagesArray[$id][$p]['filename']; ?></td> <td width="22%"><nobr><?php echo $pagesArray[$id][$p]['display_name']; ?></nobr></td> <td width="22%"><input type="text" name="<?php echo 'alternate_name_' . $id . '_' . $p; ?>" value="<?php echo $pageSettings[$p]['alternate_page_name']; ?>" maxlength="255" size="24"></td> <td width="22%"><input type="text" name="<?php echo 'anchor_text_' . $id . '_' . $p; ?>" value="<?php echo $pageSettings[$p]['anchor_text']; ?>" maxlength="255" size="24"></td> <td><input type="text" name="<?php echo 'sort_order_' . $id . '_' . $p; ?>" value="<?php echo $pageSettings[$p]['sortorder']; ?>" maxlength="2" size="3"></td> Jack 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...
Guest Posted January 2, 2009 Share Posted January 2, 2009 Wow, don't know how I missed that. I know I tested it at one point. Anyway, in admin/sietmap_seo_page_control.php, find this code at line 205 <td><input type="checkbox" name="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" id="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" <?php echo $pageSettings[$p]['excluded']; ?> maxlength="2" size="3"></td> <td width="22%"><?php echo $pagesArray[$id][$p]['filename']; ?></td> <td width="22%"><nobr><?php echo $pagesArray[$id][$p]['display_name']; ?></nobr></td> <td width="22%"><input type="text" name="<?php echo 'alternate_name_' . $id . '_' . $p; ?>" maxlength="255" size="24"></td> <td width="22%"><input type="text" name="<?php echo 'anchor_text_' . $id . '_' . $p; ?>" maxlength="255" size="24"></td> <td><input type="text" name="<?php echo 'sort_order_' . $id . '_' . $p; ?>" maxlength="2" size="3"></td> and change it to <td><input type="checkbox" name="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" <?php echo $pageSettings[$p]['excluded']; ?> id="<?php echo 'exclude_page_' . $id . '_' . $p; ?>" <?php echo $pageSettings[$p]['excluded']; ?> maxlength="2" size="3"></td> <td width="22%"><?php echo $pagesArray[$id][$p]['filename']; ?></td> <td width="22%"><nobr><?php echo $pagesArray[$id][$p]['display_name']; ?></nobr></td> <td width="22%"><input type="text" name="<?php echo 'alternate_name_' . $id . '_' . $p; ?>" value="<?php echo $pageSettings[$p]['alternate_page_name']; ?>" maxlength="255" size="24"></td> <td width="22%"><input type="text" name="<?php echo 'anchor_text_' . $id . '_' . $p; ?>" value="<?php echo $pageSettings[$p]['anchor_text']; ?>" maxlength="255" size="24"></td> <td><input type="text" name="<?php echo 'sort_order_' . $id . '_' . $p; ?>" value="<?php echo $pageSettings[$p]['sortorder']; ?>" maxlength="2" size="3"></td> Jack Thanks once again Jack for the quick reply and remedy, the new code did the trick. Further testing tomorrow. Quote Link to comment Share on other sites More sharing options...
princebaskar Posted January 2, 2009 Share Posted January 2, 2009 Hi Jack: This is a wonderfull contribution. I've it installed and seems to work fine with the corrections made in the code for the previous feedbacks. However I say "seems" because I'm a newbie and do not know if the categories box can be controlled in the Sitemap SEO admin panel or If i made a mistake in the configuration or installation that do not let me select in the "Boxes Group Control" any other box than the defined in "information.php". What may be wrong? Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 2, 2009 Author Share Posted January 2, 2009 Boxes that don't have hardcoded links won't show up in admin, at least not correctly. The only way to do that would be to use the code from the categoris box and create and save the links that code creates. The problem with that is that there are many category boxes available so for each one, another set of code would have to be copied and changed. It is just too much to try to code for. Jack 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...
Guest Posted January 2, 2009 Share Posted January 2, 2009 Hey Jack, first ... thanx for this contrib! It now works in an STS (not being used as a shop, but as a CMS). I have 2 problems by using SEO Sitmap. MySQL5, and PHP5. 1.) First I had the same problem as Coopco. After making your fix, the listing of the first 36 pages went well, even when updated. But the rest still doesn't keep the updates. (Screenshot attached) 2.) No articles are shown ... I checked the install.txt several times, but cann't find a mistake made by me! (so it doesn't mean, I made none!) Thany again!! :rolleyes: Michael Quote Link to comment Share on other sites More sharing options...
jsi Posted January 2, 2009 Share Posted January 2, 2009 Hey Jack, Great contribution!!! 2 little things . . . 1. When I go to Configuration>SiteMap SEO I notice you can change the heading text. However it does not support other languages. Is there a fix so it can support more languages? I need to add spanish. 2. Is there a way to add a button to generate a sitemap XML file? sitemap.xml However, it would be best to not auto send to google. I do advanced SEO manually and its best if I send to google myself after I play with the file. You may want to add a second button to create and send to google for other people if you want but I think its best to keep them separate. Just a generate sitemap.xml file is good enough for me. What do you think? Thanx Jack and great work! P.S. My site is english/spanish. I'll give you the spanish translations to this if you want them for others to use. I already translated them. Let me know if you would like this. Quote mmmmmmmmmmmm. Doughnuts . . . haha. i said nuts. Link to comment Share on other sites More sharing options...
tudoroiuj Posted January 3, 2009 Share Posted January 3, 2009 (edited) hei great add on i have a problem on: admin/sitemap_seo_box_control.php the error messsage is : Select a Box Note: This is a multi-select list so more than one item can be selected at once. Fatal error: Cannot use string offset as an array in /admin/includes/functions/sitemap.php on line 410 Thank you! Edited January 3, 2009 by tudoroiuj Quote Link to comment Share on other sites More sharing options...
jsi Posted January 3, 2009 Share Posted January 3, 2009 heigreat add on i have a problem on: admin/sitemap_seo_box_control.php the error messsage is : Select a Box Note: This is a multi-select list so more than one item can be selected at once. Fatal error: Cannot use string offset as an array in /admin/includes/functions/sitemap.php on line 410 Thank you! Post #3 answered this problem: As for the multi-select, at line 406 in the admin/includes/functions/sitemap.php file, change else to this: else if (tep_not_null($selected_vals)) Quote mmmmmmmmmmmm. Doughnuts . . . haha. i said nuts. Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 3, 2009 Author Share Posted January 3, 2009 A new version has been uploaded. It fixes most of the problems found so far. It may not be necessary but I suggest running the uninstall and install files to reset the pages table (or just empty that one in phpmyadmin). The problem with all of the pages not being counted could have resulted in extra pages being added to that table. It would depend on the setup of the shop so I can't say for sure but it is probably best to clear it. Jack 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 January 3, 2009 Author Share Posted January 3, 2009 1.) First I had the same problem as Coopco. After making your fix, the listing of the first 36 pages went well, even when updated. But the rest still doesn't keep the updates. (Screenshot attached)2.) No articles are shown ... I checked the install.txt several times, but cann't find a mistake made by me! (so it doesn't mean, I made none!) 1 - I just uploaded a new version that will fix this problem. 2 - Is Articles Manager enabled in the admin->configuration settings? Does the articles box show up in the Boxes Group Control section? Is it not marked as excluded or registered only? Jack 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...
princebaskar Posted January 3, 2009 Share Posted January 3, 2009 A new version has been uploaded. It fixes most of the problems found so far. It may not be necessary but I suggest running the uninstall and install files to reset the pages table (or just empty that one in phpmyadmin). The problem with all of the pages not being counted could have resulted in extra pages being added to that table. It would depend on the setup of the shop so I can't say for sure but it is probably best to clear it. Jack Hi Jack, Thanks for the quick reply. Regarding the new version Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 3, 2009 Author Share Posted January 3, 2009 1. When I go to Configuration>SiteMap SEOI notice you can change the heading text. However it does not support other languages. Is there a fix so it can support more languages? I need to add spanish. 2. Is there a way to add a button to generate a sitemap XML file? sitemap.xml However, it would be best to not auto send to google. I do advanced SEO manually and its best if I send to google myself after I play with the file. You may want to add a second button to create and send to google for other people if you want but I think its best to keep them separate. Just a generate sitemap.xml file is good enough for me. What do you think? Thanx Jack and great work! P.S. My site is english/spanish. I'll give you the spanish translations to this if you want them for others to use. I already translated them. Let me know if you would like this. 1 - Hmm, that is a design problem. I had started to add an extra section to do that but then decided on the settings. Obviously, I didn't think that through. I will add that in the next version. 2 - One of this reasons this contribution was written, as opposed to updating the Dynamic Sitemap, which was also mine, is because someone had added an xml sitemap to it. I said from the beginning that that was a mistake, which it still is, as some are finding out. The problem is that the xml sitemap entries won't match the actual url's if a url rewriter, like Ultimate SEO, is installed. That can cause duplicate content problems with the search engines. And since, I think, the majority of sites use a url rewriter, adding xml code to this contribution would introduce the same problem. The best solution is to install the google sitemap contribution by Chemo (v 1.3). Thank you for the offer of the translations. Please email them if you like and I will add them to the next version. Jack 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...
princebaskar Posted January 3, 2009 Share Posted January 3, 2009 A new version has been uploaded. It fixes most of the problems found so far. It may not be necessary but I suggest running the uninstall and install files to reset the pages table (or just empty that one in phpmyadmin). The problem with all of the pages not being counted could have resulted in extra pages being added to that table. It would depend on the setup of the shop so I can't say for sure but it is probably best to clear it. Jack Hi Jack: There is any possibility to make the code changes manually from Version 1 to 1.1, without uninstall and reinstall the new version? I made the two proposed code change for the previous feedbacks in a heavy modified site (that I do not have the expertise yet to manage!). I need the not documented change (the third one): - Fixed code in sitemap_seo_page_control.php so the checkboxes are updated correctly. Thanks! Quote Link to comment Share on other sites More sharing options...
Jack_mcs Posted January 3, 2009 Author Share Posted January 3, 2009 The only file changes were to the admin/sitemap_seo_page_control.php and admin/includes/functions/sitemap.php files. You can safely upload those to your installation and the contribution will be updated. Although you may want to note what I said about clearing the one table. Jack 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...
jsi Posted January 3, 2009 Share Posted January 3, 2009 The only file changes were to the admin/sitemap_seo_page_control.php and admin/includes/functions/sitemap.php files. You can safely upload those to your installation and the contribution will be updated. Although you may want to note what I said about clearing the one table. Jack This is probably faster. However I didnt really follow the clearing table. How does one do that? phpMyAdmin??? Thanx. - Regarding the Google XML thing, you're right. Its best to keep them apart. Any thoughts on when the next version is coming out for the translation of titles? Thanx. P.S. Will send you the spanish versions tomorrow. Kinda booked at the moment. Quote mmmmmmmmmmmm. Doughnuts . . . haha. i said nuts. 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.