Sábado, 01 Noviembre 2014 00:31
beggarly

HTTPS Problem

Report Xmap bugs on this forum.

Re: HTTPS Problem

Postby Richard67 » Tue Oct 30, 2012 3:35 pm

guilleva wrote:I need to take some time to try to reproduce the problem, that isn't very clear on the original post either, and then apply the fix and test.

Well, the problem was that in XML view, all URLs were starting with "https", regardless of the settings for the menu link, and in the HTML view the https links were not included.
But in both html and xml views, URLs should be starting with https or http as specified with the secure settings of the Joomla menu item.
To solve the first problem, line 72 of com_xmap/views/xml/tmpl/default_class.php has to be changed as follows:
Old
Code: Select all
$link = JRoute::_($node->link, true, (@$node->secure? 1: -1));

New
Code: Select all
$link = JRoute::_($node->link, true, @$node->secure==0? -1: $node->secure);

To solve the second problem, line 82 of com_xmap/views/html/tmpl/default_class.php has to be changed to the same code as follows:
Old
Code: Select all
$link = JRoute::_($node->link);

New
Code: Select all
$link = JRoute::_($node->link, true, @$node->secure==0? -1: $node->secure);

Line numbers based on files in latest available version 2.3.0.
Richard67
Fresh Boarder
Fresh Boarder
 
Posts: 6
Joined: Sun Apr 22, 2012 7:16 am

Re: HTTPS Problem

Postby Richard67 » Mon Nov 19, 2012 7:54 pm

Hi,
as far as I can see, the first change for the xml view mentioned in my post just before this one is included in the meanwhile latest version 2.3.1, but the second change for the html view not.
I haven't checked the html view, because I use only xml view, and so maybe the second change is not necessary?
If possible, guilleva please answer here so later readers will know the status of the second change.
Richard67
Fresh Boarder
Fresh Boarder
 
Posts: 6
Joined: Sun Apr 22, 2012 7:16 am

Re: HTTPS Problem

Postby guilleva » Mon Nov 19, 2012 8:37 pm

Hi,

Yes, I have applied the fixes described on your post, you can see them on this commit:
https://github.com/guilleva/Xmap/commit/37fbdd2b6766f56c5317c1468680dc380395d906

I just made a change on the second fix because your solution forces the urls to build URLs including the protocol and the domain for links that doesn't require it, but the result should be the same.

Please let me know if something doesn't work as it should.

Thanks again,

Guille
User avatar
guilleva
Administrator
Administrator
 
Posts: 1527
Joined: Wed Sep 12, 2007 3:10 am
Location: San José, Costa Rica

Re: HTTPS Problem

Postby greniers » Mon Feb 18, 2013 2:57 pm

Thank you for the changes you made into your software. I'm happy that the changes I proposed in this post are now included. It is greatly appreciated. This seems to work well.
Stéphane
greniers
Fresh Boarder
Fresh Boarder
 
Posts: 5
Joined: Fri Jan 06, 2012 4:34 am

Re: HTTPS Problem

Postby thetravels » Tue Jun 04, 2013 12:48 am

I confirmed all these changes, but xml site is still rendering http. i have whole site as https. What am i missing?
all software is uptodate
thetravels
Fresh Boarder
Fresh Boarder
 
Posts: 5
Joined: Tue Apr 09, 2013 7:02 am

Re: HTTPS Problem

Postby mhehm » Wed Jun 12, 2013 5:33 am

Hi,
Fix:
in Joomla root /components/com_xmap/views/xml/tmpl/default_class.php
search:
Code: Select all
$link = JRoute::_($node->link, true, @$node->secure==0? -1: $node->secure);

change it to:
Code: Select all
$link = JRoute::_($node->link, true, @$node->secure == 0 ? (JFactory::getURI()->isSSL() ? 1 : -1) : $node->secure);
User avatar
mhehm
Senior Boarder
Senior Boarder
 
Posts: 71
Joined: Sun Jan 20, 2013 1:22 pm
Location: Iran

Previous

Return to Bugs



Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest

cron