Changeset 592

Show
Ignore:
Timestamp:
09/28/07 11:31:45 (1 year ago)
Author:
laurentj
Message:

fixed bug #290: use of mktime generated strict message, replace it by time

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/1.0beta3.x/lib/jelix/plugins/coord/auth/auth.coord.php

    r587 r592  
    55* @author     Croes Gérald 
    66* @contributor  Laurent Jouanneau, Frédéric Guillot, Antoine Detante 
    7 * @copyright  2001-2005 CopixTeam, 2005-2006 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
     7* @copyright  2001-2005 CopixTeam, 2005-2007 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
    88* 
    99* This class was get originally from an experimental branch of the Copix project 
     
    7070            } 
    7171        } 
    72          
     72 
    7373        //Creating the user's object if needed 
    7474        if (! isset ($_SESSION[$this->config['session_name']])){ 
     
    8080        if(!$notLogged && $this->config['timeout']){ 
    8181            if(isset($_SESSION['JELIX_AUTH_LASTTIME'])){ 
    82                 if((mktime() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
     82                if((time() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
    8383                    $notLogged = true; 
    8484                    jAuth::logout(); 
    8585                    unset($_SESSION['JELIX_AUTH_LASTTIME']); 
    8686                }else{ 
    87                     $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     87                    $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    8888                } 
    8989            }else{ 
    90                 $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     90                $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    9191            } 
    9292        } 
  • branches/1.0beta3.x/lib/jelix/plugins/coord/auth/auth.coord.php

    r587 r592  
    55* @author     Croes Gérald 
    66* @contributor  Laurent Jouanneau, Frédéric Guillot, Antoine Detante 
    7 * @copyright  2001-2005 CopixTeam, 2005-2006 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
     7* @copyright  2001-2005 CopixTeam, 2005-2007 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
    88* 
    99* This class was get originally from an experimental branch of the Copix project 
     
    7070            } 
    7171        } 
    72          
     72 
    7373        //Creating the user's object if needed 
    7474        if (! isset ($_SESSION[$this->config['session_name']])){ 
     
    8080        if(!$notLogged && $this->config['timeout']){ 
    8181            if(isset($_SESSION['JELIX_AUTH_LASTTIME'])){ 
    82                 if((mktime() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
     82                if((time() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
    8383                    $notLogged = true; 
    8484                    jAuth::logout(); 
    8585                    unset($_SESSION['JELIX_AUTH_LASTTIME']); 
    8686                }else{ 
    87                     $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     87                    $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    8888                } 
    8989            }else{ 
    90                 $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     90                $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    9191            } 
    9292        } 
  • trunk/lib/jelix/plugins/coord/auth/auth.coord.php

    r582 r592  
    55* @author     Croes Gérald 
    66* @contributor  Laurent Jouanneau, Frédéric Guillot, Antoine Detante 
    7 * @copyright  2001-2005 CopixTeam, 2005-2006 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
     7* @copyright  2001-2005 CopixTeam, 2005-2007 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
    88* 
    99* This class was get originally from an experimental branch of the Copix project 
     
    7070            } 
    7171        } 
    72          
     72 
    7373        //Creating the user's object if needed 
    7474        if (! isset ($_SESSION[$this->config['session_name']])){ 
     
    8080        if(!$notLogged && $this->config['timeout']){ 
    8181            if(isset($_SESSION['JELIX_AUTH_LASTTIME'])){ 
    82                 if((mktime() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
     82                if((time() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
    8383                    $notLogged = true; 
    8484                    jAuth::logout(); 
    8585                    unset($_SESSION['JELIX_AUTH_LASTTIME']); 
    8686                }else{ 
    87                     $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     87                    $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    8888                } 
    8989            }else{ 
    90                 $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     90                $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    9191            } 
    9292        } 
  • trunk/lib/jelix/plugins/coord/auth/auth.coord.php

    r582 r592  
    55* @author     Croes Gérald 
    66* @contributor  Laurent Jouanneau, Frédéric Guillot, Antoine Detante 
    7 * @copyright  2001-2005 CopixTeam, 2005-2006 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
     7* @copyright  2001-2005 CopixTeam, 2005-2007 Laurent Jouanneau, 2007 Frédéric Guillot, 2007 Antoine Detante 
    88* 
    99* This class was get originally from an experimental branch of the Copix project 
     
    7070            } 
    7171        } 
    72          
     72 
    7373        //Creating the user's object if needed 
    7474        if (! isset ($_SESSION[$this->config['session_name']])){ 
     
    8080        if(!$notLogged && $this->config['timeout']){ 
    8181            if(isset($_SESSION['JELIX_AUTH_LASTTIME'])){ 
    82                 if((mktime() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
     82                if((time() - $_SESSION['JELIX_AUTH_LASTTIME'] )> ($this->config['timeout'] *60)){ 
    8383                    $notLogged = true; 
    8484                    jAuth::logout(); 
    8585                    unset($_SESSION['JELIX_AUTH_LASTTIME']); 
    8686                }else{ 
    87                     $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     87                    $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    8888                } 
    8989            }else{ 
    90                 $_SESSION['JELIX_AUTH_LASTTIME'] =mktime(); 
     90                $_SESSION['JELIX_AUTH_LASTTIME'] = time(); 
    9191            } 
    9292        } 
Download in other formats: Unified Diff Zip Archive