0

I have stumbled across an issue with the forum module whereby if you have a site_url specified in config as protocol agnostic, i.e. minus http: or https: then the redirect after forum log-in always returns you to the site home page.

My site_url value is set as "//www.example.com" My Forum URL is set as "/forums/"

When the redirect after log-in through the forum templates occurs I get sent to:

http://www.example.com/www.example.com/forums

Any thoughts? :/

0

I am having the same settings as you have except for the http:// protocol being there.

It works pretty well for me, when I log in from the forums it takes me to the forum home.

enter image description here

| improve this answer | |
  • That's the crux of my issue... if you want the protocol to be universal then the log-in redirect for the forum fails. :/ – Nathan Pitman Feb 16 '16 at 16:31
0

I solved this eventually by adding the following to my config:

if (false !== strpos($_SERVER['REQUEST_URI'], '/forums')) {
    $config['site_url'] = 'https:'.$config['site_url'];
}

This forces the requests for the forums module to use absolute protocol and this negates the log-in redirect issue. :)

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.