Wrong URLs in emails

Started by Alcor, February 22, 2007, 12:14:12 PM

Previous topic - Next topic

Alcor

Hello.

The URLs in the emails of activation and other are wrong. These links are like

http://www.domain.com/component/option,com_smf/Itemid,74/action,activate/u,1577/code,XXXXXXX__En or
http://www.domain.com/component/option,com_smf/Itemid,74/action,profile/u,1577__Saludos,_El

(in red color the part of the URL that it does that the link not works).

I tried replace in smf.php

$message = str_replace ('____', '
to
$message = str_replace ('__', '

and the result is two underscores instead four or one instead two. How can I fix this?

Bridge version 1.1.7, SMF 1.1.2 and Joomla 1.0.12

Thank you.

Alcor

#1
Now, the link seems correct. This is the activation email sent:

Antes de que puedas ingresar, debes primero activar tu cuenta. Para hacerlo, por favor sigue este enlace:

http://www.domain.com/component/option,com_smf/Itemid,32/action,activate/u,1589/code,XXXXXXX
_
_En caso que tengas alg"XXXXXXX.


When the user click the link, in the browser address bar the URL showed is:

javascript:ol('+http://www.domain.com/component/option,com_smf/Itemid,32/action,activate/u,1589/code,XXXXXXX');

so the users cannot activate their account and the list of users awaiting activation is growing. Also, the email is not complete (in red) and it must be:

En caso que tengas algún problema con la activación, por favor usa el código "%4$s".' . "\n\n" . $txt[130];

Can you help me, please?

Alcor

If I uninstall this component (bridge 1.1.7) and I turn again to install the previous version, will it fix the problem?

The list of user awaiting activation continues growing, with 1.1.6 there wasn't this problem. :-[

shawn122

Here is the problem:

"+http://www.domain.com"


When using Hotmail, somehow and extra "+" sign gets added when using SMF Registration.  I had the same issues but it hasnt been resolved.  What I did was use the "Joomla Registration" option in the Bridge component.
SB Creations - http://www.shawnbinda.com

Alcor

Oh! then, the problem hasn't a solution in this moment. Yes, I use the SMF registration because I like the Visual verification, this option isn't in Joomla registration nor bridge registration, but I will set again the bridge registration to avoid emails problems.
Thank you.

Orstio

Try changing the integrate_outgoing_email function in smf.php to this:

function integrate_outgoing_email($subject, &$message, $headers)
{
global $boardurl, $mosConfig_live_site, $Itemid, $scripturl, $mosConfig_sef, $modSettings, $Itemid, $hotmail_fix;

//First, we need to set up the email so that ob_mambofix knows what to do with it
$message = str_replace ($scripturl, '="' . $scripturl, $message);
$message = preg_replace ('/(http.+)(\b)/', '$1"', $message);
$message = ob_mambofix($message);
//Now we need to undo those changes so the email looks normal again
$message = str_replace ('="', '', $message);
$message = preg_replace ('/(http.+)(")/', '$1', $message);
//THis is an email, after all, so let's make sure entities and special characters are text, not HTML
$message = trim($message);
    $message = html_entity_decode($message);
$message = un_htmlspecialchars($message);
$hotmail_fix = false;
return true;
}

imrich

This seemed to help me with some users. I'd like to see this in the list of bugs fixed.

Thanks for your help!

zigzag

I'm having a problem with activation links sent to hotmail accounts, the activation link has a + in front of the http:// bit e.g. +http:// so the link returns a 404 error. I tried the fix above but now the activation link isn't clickable.

Orstio

Try deleting this line?

$hotmail_fix = false;

zigzag

Hi,
tried that but the links still not clickable.

Orstio

You realize it won't change emails already sent?

zigzag

 :D Yes, I was using the resend activation email feature.

barao

where is smf.php???

can't find it...

Orstio

In your components/com_smf folder.

Advertisement: