示例#1
0
<?php

ob_start();
session_start();
require_once 'config.php';
if (!empty($_POST)) {
    try {
        $user_obj = new Cl_User();
        $data = $user_obj->login($_POST);
        if (isset($_SESSION['logged_in']) && $_SESSION['logged_in']) {
            header('Location: index3.php');
        }
    } catch (Exception $e) {
        $error = $e->getMessage();
    }
}
if (isset($_SESSION['logged_in']) && $_SESSION['logged_in']) {
    header('Location: index2.php');
}
?>
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=0.5">
    <title>Smart Login Page</title>
	<link href='http://fonts.googleapis.com/css?family=Pacifico' rel='stylesheet' type='text/css'>
    <!-- Bootstrap -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/font-awesome.min.css" rel="stylesheet">
示例#2
0
<?php

require_once 'config.php';
if (!empty($_POST)) {
    try {
        $user_obj = new Cl_User();
        $data = $user_obj->forgetPassword($_POST);
        if ($data) {
            $success = PASSWORD_RESET_SUCCESS;
        }
    } catch (Exception $e) {
        $error = $e->getMessage();
    }
}
?>
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Password Reset</title>

    <!-- Bootstrap -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/font-awesome.min.css" rel="stylesheet">
    <link href="css/login.css" rel="stylesheet">

    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
示例#3
0
<?php

require_once 'config.php';
if (!empty($_POST)) {
    try {
        $user_obj = new Cl_User();
        $data = $user_obj->club_registration($_POST);
        if ($data) {
            $success = CLUB_REGISTRATION_SUCCESS;
        }
    } catch (Exception $e) {
        $error = $e->getMessage();
    }
}
echo "<pre>";
print_r($_POST);
echo "</pre>";
?>
<!DOCTYPE html>
<html lang="fr">
  <head>
    <meta charset="ISO8859-15">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Smart Registration Form</title>

    <link href='http://fonts.googleapis.com/css?family=Pacifico' rel='stylesheet' type='text/css'>
    <!-- Bootstrap -->
    <link href="../css/bootstrap.min.css" rel="stylesheet">
    <link href="../css/font-awesome.min.css" rel="stylesheet">
    <link href="../css/login.css" rel="stylesheet">
示例#4
0
<?php

require_once 'templates/header.php';
if (!empty($_POST)) {
    try {
        $user_obj = new Cl_User();
        $data = $user_obj->account($_POST);
        if ($data) {
            $_SESSION['success'] = PASSOWRD_CHANAGE_SUCCESS;
        }
    } catch (Exception $e) {
        $_SESSION['error'] = $e->getMessage();
    }
}
?>
<!DOCTYPE html>
<html lang="en">
        <head>
            <meta charset="utf-8">
            <meta http-equiv="X-UA-Compatible" content="IE=edge">
            <meta name="viewport" content="width=device-width, initial-scale=1">
            <meta name="description" content="">
            <meta name="author" content="">
            <title>Change Password!</title>
        	<meta charset="utf-8">
        	<meta http-equiv="X-UA-Compatible" content="IE=edge">
        	<meta name="viewport" content="width=device-width, initial-scale=1">
        	<meta name="description" content="">
        	<meta name="author" content="inventory, inventory, furniture, IMS">
        	<link href="css/custom.css" rel="stylesheet"> <!-- Custom CSS -->
        	<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"> <!-- Latest compiled and minified CSS -->
示例#5
0
    echo "</pre>";
    */
    if (isset($_POST['DELETED']) and $_POST['DELETED'] == "DELETE") {
        try {
            $user_obj = new Cl_User();
            $data = $user_obj->user_delete($_POST);
            if ($data) {
                $success = USER_DELETE_SUCCESS;
            }
            //echo '<meta http-equiv="refresh" content="0;url='.$page.'">';
        } catch (Exception $e) {
            $error = $e->getMessage();
        }
    } else {
        try {
            $user_obj = new Cl_User();
            $data = $user_obj->user_check($_POST);
            if ($data) {
                $success = USER_IS_RESPONSIBLE;
            }
            //echo '<meta http-equiv="refresh" content="0;url='.$page.'">';
        } catch (Exception $e) {
            $error = $e->getMessage();
        }
    }
}
?>
<!DOCTYPE html>
<html lang="fr">
  <head>
    <meta charset="ISO8859-15">
示例#6
0
<?php

require_once 'config.php';
if (!empty($_POST)) {
    try {
        $user_obj = new Cl_User();
        $data = $user_obj->registration($_POST);
        if ($data) {
            $success = USER_REGISTRATION_SUCCESS;
        }
    } catch (Exception $e) {
        $error = $e->getMessage();
    }
}
?>
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Join Us.</title>

    <link href='http://fonts.googleapis.com/css?family=Pacifico' rel='stylesheet' type='text/css'>
    <!-- Bootstrap -->
    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="css/font-awesome.min.css" rel="stylesheet">
    <link href="css/login.css" rel="stylesheet">

    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
示例#7
0
<?php

ob_start();
session_start();
require_once 'config.php';
//initalize user class
$user_obj = new Cl_User();
/*******Google ******/
require_once 'Google/src/config.php';
require_once 'Google/src/Google_Client.php';
require_once 'Google/src/contrib/Google_PlusService.php';
require_once 'Google/src/contrib/Google_Oauth2Service.php';
$client = new Google_Client();
$client->setScopes(array('https://www.googleapis.com/auth/plus.login', 'https://www.googleapis.com/auth/userinfo.email', 'https://www.googleapis.com/auth/plus.me'));
$client->setApprovalPrompt('auto');
$plus = new Google_PlusService($client);
$oauth2 = new Google_Oauth2Service($client);
//unset($_SESSION['access_token']);
if (isset($_GET['code'])) {
    $client->authenticate();
    // Authenticate
    $_SESSION['access_token'] = $client->getAccessToken();
    // get the access token here
    header('Location: http://' . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']);
}
if (isset($_SESSION['access_token'])) {
    $client->setAccessToken($_SESSION['access_token']);
}
if ($client->getAccessToken()) {
    $_SESSION['access_token'] = $client->getAccessToken();
    $user = $oauth2->userinfo->get();
示例#8
0
文件: logout.php 项目: Kwendou/Rexel
<?php

ob_start();
session_start();
require_once 'config.php';
$user_obj = new Cl_User();
$data = $user_obj->logout();
示例#9
0
文件: index.php 项目: zmegh/lmetfy
<?php

session_start();
ob_start();
ini_set('display_errors', 'On');
require_once 'config.php';
//initalize user class
$user_obj = new Cl_User();
if (!empty($_POST)) {
    try {
        $data = $user_obj->login($_POST);
        if (isset($_SESSION['logged_in']) && $_SESSION['logged_in']) {
            header('Location: ..\\..\\index.php');
        }
    } catch (Exception $e) {
        $error = $e->getMessage();
    }
}
//print_r($_SESSION);
if (isset($_SESSION['logged_in']) && $_SESSION['logged_in']) {
    header('Location: ..\\..\\index.php');
    exit;
}
/*** Twitter****/
require_once 'twitteroauth/twitteroauth.php';
if (TWITTER_CONSUMER_KEY === '' || TWITTER_CONSUMER_SECRET === '' || TWITTER_CONSUMER_KEY === 'TWITTER_CONSUMER_KEY_HERE' || TWITTER_CONSUMER_SECRET === 'CONSUMER_SECRET_HERE') {
    echo 'You need a consumer key and secret to test the sample code. Get one from <a href="https://dev.twitter.com/apps">dev.twitter.com/apps</a>';
    exit;
}
if (!isset($_SESSION['oauth_token'])) {
    $connection = new TwitterOAuth(TWITTER_CONSUMER_KEY, TWITTER_CONSUMER_SECRET);
示例#10
0
<?php

require_once 'config/config2.php';
if (!empty($_POST)) {
    $id = $_POST['ID'];
    if (isset($_POST['action']) and $_POST['action'] == "edit") {
    } else {
        try {
            $user_obj = new Cl_User();
            $data = $user_obj->user_update($_POST);
            if ($data) {
                $success = USER_UPDATE_SUCCESS;
            }
            //echo '<meta http-equiv="refresh" content="0;url='.$page.'">';
        } catch (Exception $e) {
            $error = $e->getMessage();
        }
    }
}
/*
echo "<pre>";
print_r($_POST);
echo "</pre>";
echo "ID=".$id."<br>";	
*/
?>
<!DOCTYPE html>
<html lang="fr">
  <head>
    <meta charset="ISO8859-15">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
示例#11
0
<?php

ob_start();
session_start();
require_once 'config.php';
//initalize user class
$user_obj = new Cl_User();
/*** Twitter****/
require_once 'twitteroauth/twitteroauth.php';
/*** Twitter****/
/*******Google ******/
require_once 'Google/src/config.php';
require_once 'Google/src/Google_Client.php';
require_once 'Google/src/contrib/Google_PlusService.php';
require_once 'Google/src/contrib/Google_Oauth2Service.php';
/*******Google ******/
/*********Facebook Login **********/
require_once 'Facebook/FacebookSession.php';
require_once 'Facebook/FacebookRedirectLoginHelper.php';
require_once 'Facebook/FacebookRequest.php';
require_once 'Facebook/FacebookResponse.php';
require_once 'Facebook/FacebookSDKException.php';
require_once 'Facebook/FacebookRequestException.php';
require_once 'Facebook/FacebookAuthorizationException.php';
require_once 'Facebook/GraphObject.php';
require_once 'Facebook/GraphUser.php';
require_once 'Facebook/GraphSessionInfo.php';
require_once 'Facebook/HttpClients/FacebookHttpable.php';
require_once 'Facebook/HttpClients/FacebookCurl.php';
require_once 'Facebook/HttpClients/FacebookCurlHttpClient.php';
require_once 'Facebook/Entities/AccessToken.php';