linea21-core
[ class tree: linea21-core ] [ index: linea21-core ] [ all elements ]

Source for file modpass.php

Documentation is available at modpass.php

  1. <?php
  2. /**
  3.  * @package linea21.core
  4.  * @subpackage user
  5.  * @author linea21 <info@linea21.com>
  6.  * @version $id SVN
  7.  * @access public
  8.  * @license http://opensource.org/licenses/gpl-3.0.html
  9.  */
  10.  
  11. //////////// Check Inclusion de pages ////////////
  12. if (!function_exists('AuthenthificationProcess')) {
  13.   include_once("../lib/lib_common.php");
  14.   ReloadIndex('admin');
  15. }
  16. ////////////
  17.  
  18. //////////// Check Droits utilisateur ////////////
  19. if (!IsSuperAdmin()) ReloadIndex('admin');
  20. ////////////
  21.  
  22. if(isset($_POST['id']))    $id=$_POST['id'];
  23. if(isset($_GET['id']))    $id=$_GET['id'];
  24.  
  25. $requete=SQL_getAllUserInfo($id);
  26. $result=$sql_object->DBSelect($requete);
  27. if($result==|| count($result)!=1exit;
  28. $user_email=$result[0]['profile_email'];
  29. $user_login=$result[0]['user_login'];
  30.  
  31. $user_objectnew user;
  32. $new_pass=$user_object->GetNewPassword();
  33. $result=$user_object->UpdateUserPassword($id$new_pass$sql_object);
  34. /** include envoi de mail */
  35. $todo_mail='change_pass';
  36. include_once(themePath('../user/mail_actions.php'));
  37. include_once('../mail/template.php');
  38. /** end mail */
  39. $link_confirm="confirm.php?rub=".$rub."&todo=".$todo;
  40. if($resultheader("Location: ".$link_confirm);
  41. else  system_error();
  42. ?>

Documentation generated on Thu, 03 May 2012 15:06:36 +0200 by phpDocumentor 1.4.1