Arreglo de URL de formulario de registro (mayúsculas / minúsculas)
git-svn-id: https://192.168.0.254/svn/Proyectos.Incam_PROFIND_Web/trunk@9 3fe1ab16-cfe0-e34b-8c9f-7d8c168d430d
This commit is contained in:
parent
2d40f3a5c8
commit
69f97dc7ed
@ -11,13 +11,19 @@ class RegistroUsuarioController extends Controller {
|
|||||||
$this->layout = '/layouts/mensajes';
|
$this->layout = '/layouts/mensajes';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function accessRules()
|
public function filters() {
|
||||||
{
|
return array('accessControl');
|
||||||
|
}
|
||||||
|
|
||||||
|
public function accessRules() {
|
||||||
return array(
|
return array(
|
||||||
array('allow',
|
array('allow',
|
||||||
'actions' => array('registrar', 'activar'),
|
'actions' => array('registrar', 'activar'),
|
||||||
'users' => array('*')
|
'users' => array('*')
|
||||||
),
|
),
|
||||||
|
array('allow',
|
||||||
|
'users' => array('@')
|
||||||
|
),
|
||||||
array('deny'),
|
array('deny'),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -122,8 +128,7 @@ class RegistroUsuarioController extends Controller {
|
|||||||
$this->render('error_confirmacion');
|
$this->render('error_confirmacion');
|
||||||
Yii::log("Incorrect activation URL. 2 ");
|
Yii::log("Incorrect activation URL. 2 ");
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$this->render('error_confirmacion');
|
$this->render('error_confirmacion');
|
||||||
Yii::log("Incorrect activation URL. 1");
|
Yii::log("Incorrect activation URL. 1");
|
||||||
}
|
}
|
||||||
@ -137,7 +142,7 @@ class RegistroUsuarioController extends Controller {
|
|||||||
private function enviarMailRegistro($usuario) {
|
private function enviarMailRegistro($usuario) {
|
||||||
Yii::import('ext.yii-mail.YiiMailMessage');
|
Yii::import('ext.yii-mail.YiiMailMessage');
|
||||||
|
|
||||||
$url_activacion = $this->createAbsoluteUrl('registrousuario/activar', array("key" => $usuario->clave_seguridad, "email" => $usuario->email));
|
$url_activacion = $this->createAbsoluteUrl('registroUsuario/activar', array("key" => $usuario->clave_seguridad, "email" => $usuario->email));
|
||||||
$mensaje = new YiiMailMessage;
|
$mensaje = new YiiMailMessage;
|
||||||
|
|
||||||
$mensaje->from = Yii::app()->params['email_remitente'];
|
$mensaje->from = Yii::app()->params['email_remitente'];
|
||||||
@ -148,8 +153,7 @@ class RegistroUsuarioController extends Controller {
|
|||||||
array(
|
array(
|
||||||
'url' => $url_activacion,
|
'url' => $url_activacion,
|
||||||
'email' => $usuario->email
|
'email' => $usuario->email
|
||||||
),
|
), 'text/html'
|
||||||
'text/html'
|
|
||||||
);
|
);
|
||||||
|
|
||||||
Yii::app()->mail->send($mensaje);
|
Yii::app()->mail->send($mensaje);
|
||||||
@ -173,5 +177,4 @@ class RegistroUsuarioController extends Controller {
|
|||||||
Yii::app()->mail->send($mensaje);
|
Yii::app()->mail->send($mensaje);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user