Ejemplo n.º 1
0
            header("Location:/signup/email_sent.php");
            exit;
            break;
            //If they are already validated
        //If they are already validated
        case 2:
            //Redirect
            header("Location:/me");
            exit;
            break;
    }
}
//Close the connection
mysqli_close($con);
HTML::begin();
Head::make("Terms and Conditions");
Body::begin();
?>

			<div id="trmcnt" style="margin-top:20px;margin-bottom:20px;">
				<h1 class="uk-text-center" style="padding-bottom:1em;">Agreeing to the Terms of Service</h1>
				<div id="trmbx" style="white-space:normal;">
					<?php 
//Get the terms out of the HTM file
echo file_get_contents("terms.htm");
?>
				</div>

				<div class="text_medium uk-text-center" style="padding-top:10px;padding-bottom:10px;">You must agree to the above terms before you can create your account.</div>
				<div class="uk-text-center">
					<a href="/signup/validate.php" class="button_primary green">I Agree</a>
Ejemplo n.º 2
0
    $master_array = array("points" => $points, "description" => $_POST["rate_desc"]);
    //Push it
    array_push($userRank, $master_array);
    //Set the new ranking array
    //Because we're changing someone else's information, we can't use the API
    $query = "UPDATE `usr` SET `rank`='" . mysqli_real_escape_string($con, json_encode($userRank)) . "' WHERE `id`='" . mysqli_real_escape_string($con, $otherInfo[0]["id"]) . "'";
    mysqli_query($con, $query);
    //Add the user to the array of people who ranked
    array_push($who_ranked, $_SESSION["userid"]);
    mysqli_query($con, "UPDATE `exchange` SET `who_ranked`='" . mysqli_real_escape_string($con, json_encode($who_ranked)) . "' WHERE `id`='" . mysqli_real_escape_string($con, $oid) . "'");
    sendNotify($other_id, "Someone has ranked you!", "profile.php?id={$other_id}");
    header("Location:/");
}
/* * * END USER RANKING SCRIPT * * */
HTML::begin();
Head::make("Exchange with {$other_fname} {$other_lname} | {$i1name}  for {$i2name}", false);
Body::add_action("pre_exchange()");
Body::add_action("codeAddress('{$address}')");
Body::begin();
//This converts the first name of the other user to a JavaScript variable for us to use later.
echo "<script>var fname = \"{$other_fname}\";</script>";
?>

		<style type="text/css">
		#banner { border-bottom:none !important; }
		</style>

			<?php 
/* * * PRINT OUT THE CHAT PANEL * * */
//The head
$chat_head = <<<BOB
Ejemplo n.º 3
0
        echo $profile_pic;
        //Print the image contents
        exit;
        //Exit
    }
    //Change the profile picture to use the URL instead
    $profile_pic = "/profile.php?id=" . $_GET["id"] . "&load=image";
} catch (Exception $e) {
    //If the person can't be found, throw a not found page
    if ($personInfo == 404) {
        header('Location:/notfound.php');
        exit;
    }
}
HTML::begin();
Head::make("{$fname} {$lname}", true);
Body::begin(true, true);
?>
<style type="text/css">
.prefix{ display:inline-block; margin-left:25px; vertical-align:top;margin-right:10px; display:inline-block; font-size:18px; }
</style>

<div id="profile_container">
	<div id="profile">
	
		<div id="cover" style="background-image:url('/profile.php?id=<?php 
echo $_GET["id"];
?>
&load=image&filter=blur&size=huge')">
			<div class="layout-1200 uk-container-center">
				<div class="uk-grid">
Ejemplo n.º 4
0
if (isset($_POST["offer"]) && trim($_POST["offer"]) != "") {
    //Get info about the offered item
    $itemCheck = new Item(array("action" => "get", "filter" => array("id" => $_POST["offer"])));
    $itemRet = $itemCheck->run(true);
    //If the item exists
    if (is_array($itemRet) && count($itemRet) != 0) {
        //Use the API to make the offer
        $offerItem = new Item(array("action" => "offer", "id" => $_GET["itemid"], "offer" => $_POST["offer"]));
        $offerItem->run();
    }
    //Redirect to a non-post-form page
    header("Location: /" . $url);
    exit;
}
HTML::begin();
Head::make($name, true);
Body::begin();
?>
			
			<div id="lightbox" class="uk-modal">
			    <div class="uk-modal-dialog uk-modal-dialog-frameless">
			        <a href="" class="uk-modal-close uk-close uk-close-alt"></a>
			        <img style="width:100%;" src="/imageviewer/?id=<?php 
echo $_GET["itemid"];
?>
" alt="<?php 
echo $name;
?>
">
			    </div>
			</div>
Ejemplo n.º 5
0
 * Copyright 2014 eDart
 *
 * [Do not remove this header. One MUST be included at the start of every page/script]
 *
 */
include_once $_SERVER["DOC_ROOT"] . "/scripts/php/core.php";
//Import core functionality
//If the user is not logged in...
if (!isset($_SESSION["userid"])) {
    header("Location: /");
    //Send them home
    exit;
    //Exit
}
HTML::begin();
Head::make("Validate Email");
Body::begin();
//Connect to MySQL
$con = mysqli_connect(host(), username(), password(), mainDb());
//Delete any previous validation keys from the server
mysqli_query($con, "DELETE FROM validate WHERE `id`='" . mysqli_real_escape_string($con, $_SESSION["userid"]) . "'");
//Generate a 256 character validation key
$ukey = random_key(256);
//Put the key in the table with the user ID attached
$set_key = "INSERT INTO validate(`id`, `key`) VALUES ('" . mysqli_real_escape_string($con, $_SESSION["userid"]) . "', '" . mysqli_real_escape_string($con, $ukey) . "')";
mysqli_query($con, $set_key);
//Close the connection
mysqli_close($con);
//Get info about the current user
$curuser = new User(array("action" => "get", "id" => $_SESSION["userid"]));
$uinfo = $curuser->run(true);
Ejemplo n.º 6
0
    }
    return $items;
    //Return the master array
}
$total = 0;
//Total line count
$files = getFiles();
//Get all of the directories throughout the entire directory
//Loop through
foreach ($files as $f) {
    $total += countLines($f);
    //and add the line count
}
//We'll print this out all later.
HTML::begin();
Head::make("About Us");
Body::begin();
?>
		<style>

		#code_count { border-top:1px solid green; font-family:TitilliumrRegular,Trebuchet MS, sans-serif;font-size:45px;color:green; padding:25px !important; text-align:center;}

		</style>
			<div style="min-height:520px;" class="layout-1200 uk-container-center">
				<div class="uk-grid">
					<div class="uk-width-medium-1-5">
						<ul id="about_nav" class="uk-nav uk-nav-side" data-switcher-parent="#panel_parent">
						    <li><a data-switcher-id="#story">Story</a></li>
						    <li><a data-switcher-id="#team">Team</a></li>
						    <li><a data-switcher-id="#backend">Backend</a></li>
						    <li><a data-switcher-id="#contact">Contact</a></li>
Ejemplo n.º 7
0
//Import core functionality
//If there is no keyword
if (!isset($_GET["keyword"])) {
    header("Location:/");
    //Go home
    exit;
}
$keyword = $_GET["keyword"];
//Break down the keyword by spaces
$srch = explode(' ', trim(strtolower($keyword)));
HTML::begin();
//If the keyword is blank, just make it 'Search'
if (trim($_GET["keyword"]) == "") {
    Head::make("Search");
} else {
    Head::make($_GET["keyword"]);
}
Body::begin();
//Because the search bar is the same on all pages, we have to change it via JavaScript
$headsearch_script = <<<HSRCH
\t\t\t\t\t<script>
\t\t\t\t\t\tvar hsea = document.getElementById('headsearch');
\t\t\t\t\t\thsea.style.color="white";
\t\t\t\t\t\thsea.value = "{$keyword}"
\t\t\t\t\t</script>
HSRCH;
echo $headsearch_script;
?>

			<div class="layout-978 uk-container-center">
				<div class="uk-grid">
Ejemplo n.º 8
0
/* 
 * Page Name: Home
 * Purpose: Either the splash page or the feed page, depending on if the user is logged in
 * Last Updated: 6/5/2014
 * Signature: Tyler Nickerson
 * Copyright 2014 eDart
 *
 * [Do not remove this header. One MUST be included aut the start of every page/script]
 *
 */
//MUST be at the top of every file
include_once $_SERVER["DOC_ROOT"] . "/scripts/php/core.php";
//Include core functionality
HTML::begin();
Head::make("eDart", false);
//If the user is logged in...
if (isset($_SESSION["userid"])) {
    //We run a collection of feed functions
    Body::add_action("pre_feed()");
    Body::begin();
} else {
    //We run some home functions
    Body::add_action("pre_home()");
    Body::begin(true, true);
}
//If we aren't logged in, print the home/splash page
if (!isset($_SESSION["userid"])) {
    include_once $_SERVER["DOC_ROOT"] . "/scripts/php/html/home.php";
} else {
    /* * * FEED * * */
Ejemplo n.º 9
0
    //Change the title
    //Delete the validation key from the table
    mysqli_query($con, "DELETE FROM validate WHERE `key`='" . mysqli_real_escape_string($con, $key) . "'");
}
//Select the current user in the database
$user_q = mysqli_query($con, "SELECT * FROM usr WHERE id='" . mysqli_real_escape_string($con, $uid) . "'");
//If they are not fully validated, increase the validation
while ($r = mysqli_fetch_array($user_q)) {
    if ($r["status"] < 2) {
        mysqli_query($con, "UPDATE usr SET status='1' WHERE id='" . mysqli_real_escape_string($con, $uid) . "'");
    }
}
//Close the MySQL connection
mysqli_close($con);
HTML::begin();
Head::make($title);
Body::begin();
?>
			<div id="mc_cont" style="width:500px;margin-top:50px;margin-bottom:50px;">
				<div id="mc" style="width:500px;">
					<h1 class="uk-text-center" style="text-align:center;margin-bottom:10px;margin-top:10px;"><?php 
echo $head;
?>
</h1>

					<?php 
//If the validation was successful...
if ($success) {
    //...create the continue button
    echo "<table id=\"loginbx\" style=\"height:auto;width:500px;margin-top:30px;\">\n\t\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t\t<td class=\"uk-text-center\">\n\t\t\t\t\t\t\t\t\t<input \ttype=\t\"button\"\n\t\t\t\t\t\t\t\t\t\tstyle=\t\"width:100px;font-size:14px;display:block;margin:0 auto;text-align:center;\"\n\t\t\t\t\t\t\t\t\t\tclass=\t\"button_primary green\"\n\t\t\t\t\t\t\t\t\t\tonclick=\"window.location='/terms.php';\"\n\t\t\t\t\t\t\t\t\t\tvalue=\t\"Continue\"\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t</table>";
}
Ejemplo n.º 10
0
<?php

/*
 * Page Name: Generic Login Page
* Purpose: Let the user log in a possibly redirect to a target landing page
* Last Updated: 8/20/2014
* Signature: Tyler Nickerson
* Copyright 2014 eDart
*
* [Do not remove this header. One MUST be included at the start of every page/script]
*
*/
include_once $_SERVER["DOC_ROOT"] . "/scripts/php/core.php";
//Include core functionality
HTML::begin();
Head::make("Login");
Body::add_action("pre_home()");
Body::begin(true, true);
?>

<div id="home_container">
	<div class="layout-1200 uk-container uk-container-center">
			<div id="signup_panel" class="uk-width-1-1 uk-border-rounded uk-container-center uk-text-center">
				<h1>Login to eDart</h1>
					<form method="POST" onsubmit="clearIncomplete(this);" action="/signup/process.php" id="signup_form">
						<div class="uk-width-medium-1-3 uk-container-center">
							<input class="uk-width-1-1 text_medium"	name="leaddr" id="lpeaddr" autocomplete="off" type="text"     placeholder="Email Address" onkeydown="return_login(event, 'loginbtn');" />
							<input class="uk-width-1-1 text_medium"	name="lpword" id="lppword" autocomplete="off" type="password" placeholder="Password" 	 onkeydown="return_login(event, 'loginbtn');" />
										
							<?php 
$con = mysqli_connect(host(), username(), password(), mainDb());