<?php /** *Simple Auth Class * * http://pmav.eu/stuff/php-simple-auth/ * * v1.0 - 14/Set/2009 */ class SimpleAuth { private $password; function __construct($password) { $this->password = $password; } function isValid($key = 'key') { return ($_GET[$key] === md5($this->password) || $_GET[$key] === $this->password); } function getSecret() { return md5($this->password); } } ?>