OK, Installed this hack works great,
(by khuhner on 2006/10/24 1:19:43)
xoops 2.0.16 + heavy hacks...
Noticed one small syntx error in the code and added xoops-ulr(instead of yourdomain.com)..
Attached the modified one..just upload and add link into login blocks.
could not attach but here it is,
====================================re-activate.php
### ======================================================
###
XOOPS Brasil - A comunidade diferente!
### ======================================================
### Arquivo para reenvio de Link de Ativação
### Script for resend the activation link
### ======================================================
### Developer: Fernando Santos,
fernando@zend.com.br### Copyright:
http://www.xoops.net.br © 2003-2004
### ------------------------------------------------------
###
http://www.xoops.net.br### ======================================================
### v.1.0, Sun Dec 19 15:33:59 BRST 2004
### ======================================================
$xoopsOption['pagetype'] = "user";
include "mainfile.php";
include 'header.php';
// Doesn't matter GET or POST
$email = isset($HTTP_GET_VARS['email']) ? trim($HTTP_GET_VARS['email']) : '';
$email = isset($HTTP_POST_VARS['email']) ? trim($HTTP_POST_VARS['email']) : $email;
// If $email is empty, show form for link resend
if ($email == '') {
echo <<< TOPET05
TOPET05;
$email='';
// If $email is not empty, let's verify some things before sending the link
}else{
$myts =& MyTextSanitizer::getInstance();
$member_handler =& xoops_gethandler('member');
// The line below returns an array with all the users registered with the given e-mail, in our case it'll be only the
$getuser[0];
$getuser =& $member_handler->getUsers(new Criteria('email', $myts->addSlashes($email)));
// If the e-mail doesn't exist in the database, $getuser returns array()...
if ($getuser == array() ) {
echo "
E-mail " . $email . " doesn't appear to be registered in our databases!
Please click
here to retry.
";
include("footer.php");
exit();
}
// If the e-mail doesn't exist in the database, $getuser returns empty...
if (empty($getuser)) {
echo "
The e-mail isn't registered in our databases!
";
include("footer.php");
exit();
}
//Verifying if the user is already active...
if($getuser[0]->isActive()){
echo "
The user ".$getuser[0]->getVar('uname').", registered with e-mail ".$getuser[0]->getVar('email')."
is already active!
";
include("footer.php");
exit();
}
//Sending it
$xoopsMailer =& getMailer();
$xoopsMailer->useMail();
$xoopsMailer->setTemplate('register.tpl');
$xoopsMailer->assign('SITENAME', $xoopsConfig['sitename']);
$xoopsMailer->assign('ADMINMAIL', $xoopsConfig['adminmail']);
$xoopsMailer->assign('SITEURL', XOOPS_URL."/");
$xoopsMailer->setToUsers($getuser[0]);
$xoopsMailer->setFromEmail($xoopsConfig['adminmail']);
$xoopsMailer->setFromName($xoopsConfig['sitename']);
$xoopsMailer->setSubject(sprintf("- Resend - "._US_USERKEYFOR,$getuser[0]->getVar("uname")));
if ( !$xoopsMailer->send() ) {
echo "
It could not be possible to resend the activation link for ".$getuser[0]->getVar('uname').".
Contact itslbd.com Contact administrators.
";
include("footer.php");
exit();
} else {
echo "
The activation link for ".$getuser[0]->getVar('uname')." was resent. If you don't receive
the e-mail in a few hours, try again or contact the site
";
}
}
include("footer.php");
?>
=============================================
thanks for the great hack ...