Class Security

Description

Security Class

Collection of static methods for handling security within a website running on PICKLES. Requires sessions to be enabled.

Located in /classes/Security.php (line 27)


	
			
Method Summary
static boolean clearLevel ()
static boolean hasLevel (integer $access_level, [integer $user_level = null])
static boolean isLevel (mixed $access_level, [mixed $user_level = null])
static boolean setLevel (mixed $access_level)
Methods
static method clearLevel (line 112)

Clear Level

Clears out the security level.

  • return: true
  • access: public
static boolean clearLevel ()
static method hasLevel (line 161)

Has Level

Checks the user's access level against the passed level.

  • return: whether or not the user has access
  • access: public
static boolean hasLevel (integer $access_level, [integer $user_level = null])
  • integer $access_level: access level to be checked against
  • integer $user_level: optional user's access level
static method isLevel (line 131)

Is Level

Checks the user's access level is exactly the passed level

  • return: whether or not the user is that level
  • access: public
static boolean isLevel (mixed $access_level, [mixed $user_level = null])
  • mixed $access_level: access level to be checked against
  • mixed $user_level: optional user's access level
static method setLevel (line 95)

Set Level

Sets the security level.

  • return: true on success, thrown exception on error
  • access: public
static boolean setLevel (mixed $access_level)
  • mixed $access_level: access level to set this session to

Documentation generated on Sun, 17 Oct 2010 23:17:23 -0400 by phpDocumentor 1.4.3