Sunday, 21 September 2014 06:08
beggarly

https required in sitemap links

An open forum for opinions and general questions

https required in sitemap links

Postby nickweavers » Sat Apr 07, 2012 1:02 pm

I have set my Joomla global configuration server settings for Force SSL to "entire site" but Xmap doesn't appear to honour this when generating the sitemap xml. Is there some way I can force it to use https in the links rather than http? Or does googlebot not check certificates anyway making it unnecessary?

TIA,
Nick
nickweavers
Fresh Boarder
Fresh Boarder
 
Posts: 5
Joined: Sat Apr 07, 2012 12:55 pm

Re: https required in sitemap links

Postby verzosa » Sat Apr 07, 2012 2:36 pm

Hi Nick,
You need to go to each item in the menu manager.

Menu -> Metadata Options -> Secure (make sure it's on. it's probably on ignore mode)

You can see my XML sitemap here in SSL : https://discoverphils.com/index.php?option=com_xmap&view=xml&tmpl=component&id=1

Hope that helps.
verzosa
Fresh Boarder
Fresh Boarder
 
Posts: 3
Joined: Wed Apr 04, 2012 4:32 pm

Re: https required in sitemap links

Postby nickweavers » Sat Apr 07, 2012 3:23 pm

Thanks, that helps. But not all menu items show the meta data fields (such as those for external URL which can be used for user written components).

I think it would be much more convenient if the Xmap extension would honour the Gobal Configuration parm for Force SSL.

Best regards,
Nick
nickweavers
Fresh Boarder
Fresh Boarder
 
Posts: 5
Joined: Sat Apr 07, 2012 12:55 pm

Re: https required in sitemap links

Postby nickweavers » Mon Apr 09, 2012 6:05 pm

I modified my copy of com_xmap/vies/xml/tmpl/default_class.php to make it check the force_ssl site params as follows:

Code: Select all
    function printNode($node)
    {
        ...       
        // Get the item's URL
        $forceSSL = JFactory::getConfig()->get('force_ssl');
        if ($forceSSL == 2) {
         $link = JRoute::_($node->link, true, 1);
        } else {
         $link = JRoute::_($node->link, true, (@$node->secure? 1: -1));
        }
        ...



I hope the Xmap developer will consider including this in a future release, but for now the code update may help any others with the same problem.
nickweavers
Fresh Boarder
Fresh Boarder
 
Posts: 5
Joined: Sat Apr 07, 2012 12:55 pm


Return to General



Who is online

Users browsing this forum: No registered users and 2 guests

cron