Exemplo n.º 1
0
*/
include 'kidsafe-config.php';
//include ('kidsafe-includes.php');
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/** Warning do not run in debug on a production system - exposes more information */
//$debug = True;
if (!isset($debug)) {
    $debug = false;
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
//$get_values = getPostParms();
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// php session - we don't check for login status if come to this page we need to relogin
$session = new DashboardSession();
//Get parameters - check safe and return as array
// all values are included in array - even if not on url
$parms = new Parameters();
// Allow messages to be sent to the web page
$message = '';
// If we have a username & password then login attempt, if not then prompt
/** logging in **/
// First check that the password is correct - as otherwise we won't allow anything
// $password is already md5 encoded, as is the value in get_values so just do direct compare
Exemplo n.º 2
0
You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
/** Parameters **/
// Possible future options (not included)
// filter maxlines order
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    //header("Location: dashboardlogin.php?redirect=dashboard.php");
    // can't redirect within ajax so just return message
    print "Not logged in";
    exit(0);
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    header("Location: dashboardlogin.php?redirect=listrules.php");
    exit(0);
}
$parms = new Parameters();
Exemplo n.º 4
0
// addgroup - group to add (only if template not selected)
// If the site is added through addrule.php then it's a basic option - without title and comments
// It can be edited later
//$debug = true;
if (!isset($debug)) {
    $debug = false;
}
include 'kidsafe-config.php';
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
//Get parameters - check safe and return as object
// all values are included in array - even if not on url
$parms = new Parameters();
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// If we have a password then adding entry, if not then prompt what to add
/** Adding entry **/
// First check that the password is correct - as otherwise we won't allow anything
// $password is already md5 encoded, as is the value in get_values so just do direct compare
if ($parms->getParm('add') == 'stage2') {
    // gets user object based on username
    $user = $kdb->getUserUsername($parms->getParm('username'));
    // check we got a user back
    if ($user == null) {
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
//$debug=true;
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    header("Location: dashboardlogin.php?redirect=dashboard.php");
    exit(0);
}
// create user object
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    header("Location: dashboardlogin.php?redirect=password.php");
    exit(0);
}
// create user object
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    header("Location: dashboardlogin.php?redirect=listrules.php");
    exit(0);
}
$parms = new Parameters();
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
//$debug=true;
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    header("Location: dashboardlogin.php?redirect=dashboard.php");
    exit(0);
}
// create user object
Exemplo n.º 9
0
You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
if (!isset($debug)) {
    $debug = false;
}
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
//Get parameters - check safe and return as object
$parms = new Parameters();
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
if ($parms->getParm('url') == '') {
    $user_messages .= 'No website specified in the redirect. <br>';
}
// Do we have an IP address from the parms - if so use that, if not try and find from the server (only if no proxy set for local connections)
if ($parms->getParm('source') != '') {
    $ip = $parms->getParm('source');
} else {
Exemplo n.º 10
0
You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
//$debug = true;
if (!isset($debug)) {
    $debug = false;
}
include 'kidsafe-config.php';
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// Get parameters - check safe and return as object
// all values are included in array - even if not on url
$parms = new Parameters();
// used to set messages to provide to the user
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
if ($parms->getParm('message') == 'passwordmatch') {
    $user_message .= 'Passwords do not match<br>';
}
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
Exemplo n.º 11
0
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with kidsafe.  If not, see <http://www.gnu.org/licenses/>.
*/
include 'kidsafe-config.php';
// configuration (eg. mysql login)
// autoload any classes as required
function __autoload($class_name)
{
    include 'inc/' . $class_name . '.php';
}
//$debug=true;
/*** Connect to database ***/
$db = new Database($dbsettings);
$kdb = new KidsafeDB($db);
if ($db->getStatus() != 1) {
    die("Unable to connect to the database");
}
// used to set messages to provide to the user (eg. 'proxy not disabled for local network');
// including <br> on the end of each message will keep the messages separate for the user
$user_messages = '';
/** Check for login - or redirect to login.php **/
$session = new DashboardSession();
// are we logged in already?
if ($session->getUsername() == '') {
    //If not redirect to login page - then redirect here
    header("Location: dashboardlogin.php?redirect=dashboard.php");
    exit(0);
}
// create user object