function __construct($nom, $cognoms, $correu, $pass) { parent::__construct(); $this->setNom($nom); $this->setCognom($cognoms); $this->setCorreu($correu); $this->setPassword($pass); }
<?php ob_start(); session_start(); include_once '../classes/usuaris.php'; $usuari = $_POST['correu']; $pass = $_POST['pass']; $user = new usuari(); $id = $user->login($usuari, $pass); if ($id > 0) { $_SESSION['id'] = $id; header('Location: index2.php?p=1'); } else { $_SESSION['loginerror'] = 1; header('Location: index.php'); }
<th>ID</th> <th><?php echo $lang['NAME']; ?> </th> <th><?php echo $lang['EMAIL']; ?> </th> <th></th><th></th> </tr> </thead> <tbody> <?php include_once '../classes/usuaris.php'; $usuari = new usuari(); $usuari->llistar(); ?> </tbody> </table> </div> <?php $bd->close(); ?> <div class="tab-pane col-md-6 col-md-offset-3" id="categories"> <table class="table table-striped"> <thead> <tr> <th>ID</th> <th><?php echo $lang['CATEGORY'];