Menu Content

Support

> Forums, FAQs & Paid Support
Welcome, Guest
Username Password: Remember me

3.9.5 redirects unneccesarily to other domains
(1 viewing) (1) Guest
Support forum for customers who have purchased JoomSEF 3 (Joomla 1.5 compatible). Archive only, no new post can be added.

NOTE: This category has been locked. If you have purchased paid version, please, use our Support Ticket system instead. If you are using free edition, please see the Community Support section.
  • Page:
  • 1

TOPIC: 3.9.5 redirects unneccesarily to other domains

3.9.5 redirects unneccesarily to other domains 12 years, 9 months ago #28982

  • efm
  • OFFLINE
  • Posts: 8
Order # 21669

Hi,

I have 2 domains .nl & .com. Since the upgrade to 3.9.5 joomsef unneccesarily redirects between addresses that are the same on the different domains:

www.domain.nl/downloads/ (dutch download page)
www.domain.com/downloads/ (english download page)

www.domain.nl/downloads/ is not accessible anymore because joomsef keeps redirecting to www.domain.com/downloads/.

Can you please come up with an easy fix or instructions how to downgrade so i can solve this problem.

Thanks.
The topic has been locked.

Re: 3.9.5 redirects unneccesarily to other domains 12 years, 9 months ago #28995

  • dajo
  • OFFLINE
  • Posts: 5069
Hi,
Thank you for your report. Unfortunately, there's no easy solution for this problem. We'll fix it in next version of JoomSEF.
JoomSEF also cannot be downgraded, you would need to uninstall it and install it again, which would require you to backup the database tables in order not to lose your configuration and URLs.
But if you're interested, I can guide you to disable this behaviour directly in JoomSEF's source code.
ARTIO Support Team
The topic has been locked.

Re: 3.9.5 redirects unneccesarily to other domains 12 years, 9 months ago #28997

  • efm
  • OFFLINE
  • Posts: 8
If you can explain how to disable, that would be great.

Any ideas about how long it will take before a new version will be released? Should I undo the hack before upgrading to a newer version?
The topic has been locked.

Re: 3.9.5 redirects unneccesarily to other domains 12 years, 9 months ago #29001

  • dajo
  • OFFLINE
  • Posts: 5069
First of all, copy your /components/com_sef/joomsef.php file somewhere else as a backup.
Then edit it using your favorite text editor, and around line number 1230 there should be the following code:
        if (empty($lang)) {
$lang = (isset($newVars['lang']) ? $newVars['lang'] : (isset($vars['lang']) ? $vars['lang'] : null));
}
else {
// We have a language from domain, check if it corresponds to language in SEF URL
if (isset($newVars['lang']) && ($newVars['lang'] != $lang)) {
// Domain and SEF URL languages don't match
if ($sefConfig->wrongDomainHandling == _COM_SEF_WRONG_DOMAIN_REDIRECT) {
// Redirect to correct domain
if (isset($sefConfig->jfSubDomains[$newVars['lang']])) {
$domain = $sefConfig->jfSubDomains[$newVars['lang']];
$redir = JURI::getInstance();
$redir->setHost($domain);
 
// Redirect
$mainframe =& JFactory::getApplication();
$mainframe->redirect($redir->toString(), '', 'message', true);
exit();
}
 
// No domain found, show 404
$disabled = true;
}
else {
// Show 404 page
$disabled = true;
}
}
}

Just remove the "else" part of the block, so you only leave the following code there:
        if (empty($lang)) {
$lang = (isset($newVars['lang']) ? $newVars['lang'] : (isset($vars['lang']) ? $vars['lang'] : null));
}


There's currently no ETA for next JoomSEF version. You don't need to remove the modification before upgrading as the whole file will be overwritten with newer version.
ARTIO Support Team
The topic has been locked.
  • Page:
  • 1
User Login Empty