-
-
Save parzibyte/96ede831764ca34f5f54022ce57430bd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
# Si no hay datos, es decir, el usuario no está logueado... | |
if (!$this->session->has_userdata("usuario")) { | |
# Poner un mensaje de inicio de sesión | |
$this->session->set_flashdata('mensaje', 'No puedes acceder al recurso hasta que <strong>inicies sesión</strong>'); | |
# Y redireccionar al login | |
redirect("login"); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment