Need a solution?
Call Us Now!
SEO Blog
Design & Development Articles
SEO eBook
Joomla Coding Examples - Joomap Joomap 2.06 Beta - Joomla SEO patch to handle ChangeFreq, priority and lastmod | Background The last and potentially final release of Joomap and this is my patched version. Joomap is a great component for creating a sitemap on your website and is also very good for google sitemaps. The Google sitemap is essential for those wanting to approach Joomla SEO. What Joomap does is allow google to find all of the links on your site and in helping them potentially they help you. I created this solution for my efforts in Search Engine Optimisation(SEO) of Joomla CMS. The Problem The problem with Joomap is that it does not have the changefrequency, priority and lastmod fields output in the sitemap XML file. These code changes and modifications are not essential but as far as I am concerned the more information you can give Google the better. There are some other things that could be improved about this component, like selecting specific URL's which have differing change frequency etc tec but I have not been convinced this will dramatically affect my SEO efforts at this stage. Until that time I will probably not modify it much more - unless Joomap disappear, then i might take it over. The Solution You need to locate the file "/components/com_joomap/joomap.google.php" and open it in a text editor.
Replace this code | $out .= "<url>\n"; $out .= " <loc>". $link ."</loc>\n"; // http://complete-url if( isset($node->modified) && $node->modified != FALSE && $node->modified != -1) { $modified = date('Y-m-d\TH:i:s', $node->modified); // ISO 8601 yyyy-mm-ddThh:mm:ss.sTZD $modified .= sprintf("%+03d:00", $GLOBALS['mosConfig_offset']); //TimeZoneDesignator $out .= " <lastmod>". $modified ."</lastmod>\n"; | with the following code
| $out .= "<url>\n"; $out .= "<loc>". $link ."</loc>\n"; // http://complete-url $timestamp = (isset($node->modified) && $node->modified != FALSE && $node->modified != -1) ? $node->modified : time(); $modified = gmdate('Y-m-d\TH:i:s\Z', $timestamp); // ISO 8601 yyyy-mm-ddThh:mm:ss.sTZD $out .= "<changefreq>daily</changefreq>"; $out .= "<priority>0.8</priority>"; $out .= "<lastmod>{$modified}</lastmod>\n";
| Or you can download the full Joomap modified component here.
| More about web development |
Joomla Services |
Want to know more?Call 1300 880 841 or click here to contact us.