xoops forums

Mithrandir

XOOPS is my life!
Posted on: 2005/8/30 11:21
Mithrandir
Mithrandir (Show more)
XOOPS is my life!
Posts: 6320
Since: 2003/6/21
#1

Activation Link fix test

First job for the beta testing team, until we get the infrastructure finalised:

Could you try replacing
if (!strpos(XOOPS_URL"http")) {
        
//Relative URL used, calculate absolute URL
        
$protocol strtolower(substr($_SERVER['SERVER_PROTOCOL'], 0strpos($_SERVER['SERVER_PROTOCOL'], "/"0)));
        
define("XOOPS_ABS_URL"$protocol."://".$_SERVER['HTTP_HOST'].XOOPS_URL);
    }
    else {
        
define("XOOPS_ABS_URL"XOOPS_URL);
    }

with
if (strpos(XOOPS_URL"http") === 0) {
        
define("XOOPS_ABS_URL"XOOPS_URL);
    }
    else {
        
//Relative URL used, calculate absolute URL
        
$protocol strtolower(substr($_SERVER['SERVER_PROTOCOL'], 0strpos($_SERVER['SERVER_PROTOCOL'], "/"0)));
        
define("XOOPS_ABS_URL"$protocol."://".$_SERVER['HTTP_HOST'].XOOPS_URL);
    }

in include/common.php (around lines 119-126)

Then see if it fixes the activation link as well as other links in emails.

Thanks
"When you can flatten entire cities at a whim, a tendency towards quiet reflection and seeing-things-from-the-other-fellow's-point-of-view is seldom necessary."

Cusix Software

JMorris

XOOPS is my life!
Posted on: 2005/9/17 23:42
JMorris
JMorris (Show more)
XOOPS is my life!
Posts: 2722
Since: 2004/4/11
#2

Re: Activation Link fix test

Sorry it took so long to get back to you on this.

Your fix worked like a charm on MyWebResource. Looks like someone already beat me to it on the beta testing sites.

Best Regards,

James
Insanity can be defined as "doing the same thing over and over and expecting different results."

Stupidity is not a crime. Therefore, you are free to go.

Chappy

Friend of XOOPS
Posted on: 2005/9/18 3:52
Chappy
Chappy (Show more)
Friend of XOOPS
Posts: 456
Since: 2002/12/14
#3

Re: Activation Link fix test

Worked for me as well. Thanks!
MMM...It tastes like chicken! ...

jakeabiva

Just popping in
Posted on: 2005/11/16 8:06
jakeabiva
jakeabiva (Show more)
Just popping in
Posts: 20
Since: 2005/6/25
#4

Re: Activation Link fix test

Hi,

Are you ver 2.2.3? Because I did not find this code on my common.php. I'm using 2.2.3



Quote:

Mithrandir wrote:
First job for the beta testing team, until we get the infrastructure finalised:

Could you try replacing
if (!strpos(XOOPS_URL"http")) {
        
//Relative URL used, calculate absolute URL
        
$protocol strtolower(substr($_SERVER['SERVER_PROTOCOL'], 0strpos($_SERVER['SERVER_PROTOCOL'], "/"0)));
        
define("XOOPS_ABS_URL"$protocol."://".$_SERVER['HTTP_HOST'].XOOPS_URL);
    }
    else {
        
define("XOOPS_ABS_URL"XOOPS_URL);
    }

with
if (strpos(XOOPS_URL"http") === 0) {
        
define("XOOPS_ABS_URL"XOOPS_URL);
    }
    else {
        
//Relative URL used, calculate absolute URL
        
$protocol strtolower(substr($_SERVER['SERVER_PROTOCOL'], 0strpos($_SERVER['SERVER_PROTOCOL'], "/"0)));
        
define("XOOPS_ABS_URL"$protocol."://".$_SERVER['HTTP_HOST'].XOOPS_URL);
    }

in include/common.php (around lines 119-126)

Then see if it fixes the activation link as well as other links in emails.

Thanks