Exemplo n.º 1
0
require_once "includes/log.php";
require_once "includes/db_connect.php";
// Start a session.
session_start();
//*****************************************************************************
/** Functions **/
//*****************************************************************************
//*****************************************************************************
/** Main Routine **/
//*****************************************************************************
// Check that the user is logged in.
if (!is_logged_in()) {
    header("Location: signin.php");
}
// start the template
start_template();
// connect to the database
$dbc = db_connect();
// First section: User statistics
?>

<div class="container-fluid bg-1">
	<h2>Stats stuff will go here</h2>
	<h3>Blah, blah, blah.....</h3>
	<h3>Blah, blah, blah.....</h3>
</div>

<?php 
// Second section: User subjects
?>
Exemplo n.º 2
0
{
    //Get database connection
    $dbc = db_connect();
    if ($dbc == false) {
        echo 'Error: unable to connect to user database.';
    }
    $dbc = null;
}
/** Main Routine **/
//*****************************************************************************
// Check that the user is logged in.
if (!is_logged_in()) {
    header("Location: signin.php");
}
// start the template
start_template(array("css/margin.css", "css/deckList"));
if (isset($_POST['processCard']) && $_POST['processCard'] == "true") {
    addCard();
}
// First section: User statistics
?>


<!-- Create the two text areas representing the two sides-->
<!-- of a flash card.-->
<div class="container-fluid bg-1">
  <center><h2>Deck Creation</h2></center>
</div>


<form method="post" action="">
Exemplo n.º 3
0
require_once "includes/log.php";
require_once "includes/db_connect.php";
// Start a session.
session_start();
//*****************************************************************************
/** Functions **/
//*****************************************************************************
//*****************************************************************************
/** Main Routine **/
//*****************************************************************************
// Check that the user is logged in.
if (!is_logged_in()) {
    header("Location: signin.php");
}
// start the template
start_template(array("css/margin.css"));
// First section: User statistics
?>

<div class="container-fluid bg-1">
</div>

<form method="post" action="">

	<div class="form-group">
		<label for="deckName">Deck Name:</label>
		<input type="text" class="form-control" id="deckName" name="deckName">
	</div>

  <div class="form-group">
		<label for="description">Description:</label>
Exemplo n.º 4
0
function show_forms($err1 = "", $err2 = "")
{
    $cssFiles = array();
    $cssFiles[] = 'css/signin.css';
    start_template($cssFiles);
    ?>
	
	<div class="container-fluid bg-1">
		<div class="form_err" id="error1"><?php 
    echo $err1;
    ?>
</div>
		<h2>Sign In Here</h2>
		<div id="signin_form">
			<form method="post" action="" accept-charset="UTF-8">
				<div class="form-group">
					<label for="user_or_email">Username or Email</label>
					<input type="text" class="form-control" id="user_or_email" 
						name="user_or_email" maxlength="255" required>
				</div>
				<div class="form-group">
					<label for="pwd">Password</label>
					<input type="password" class="form-control" id="pwd"
						name="password" maxlength="255" required>
				</div>
				<input type="hidden" name="signin" value="true">
				<input type="submit" value="Submit" class="btn btn-default">
			</form>
		</div>
	</div>

	<div class="container-fluid bg-2">
		<div class="form_err" id="error2"><?php 
    echo $err2;
    ?>
</div>
		<h2>Don't have an account?</h2>
		<h3>
			No problem! Get access to hundreds of flashcards and quizzes
			generated by students and professors alike by creating an
			account below.
		</h3>
		<div id="signin_form">
			<form method="post" action="" accept-charset="UTF-8">
				<div class="form-group">
					<label for="des_username">Desired Username</label>
					<input type="text" class="form-control" id="des_username"
						name="des_username" maxlength="255">
				</div>
				<div class="form-group">
					<label for="des_email">Desired Email</label>
					<input type="text" class="form-control" id="des_email"
						name="des_email" maxlength="255">
				</div>
				<div class="form-group">
					<label for="">User Type</label>
					<div class="radio">
						<label>
							<input type="radio" name="type" value="0">
							Student
						</label>
					</div>
					<div class="radio">
						<label>
							<input type="radio" name="type" value="1">
							Teacher
						</label>
					</div>
				</div>
				<div class="form-group">
					<label for="des_pwd">Set Password</label>
					<input type="password" class="form-control" id="des_pwd"
						maxlength="255" name="des_pwd">
				</div>
				<div class="form-group">
					<label for="des_pwd2">Re-enter Password</label>
					<input type="password" class="form-control" id="des_pwd2"
						maxlength="255" name="des_pwd2">
				</div>
				<input type="hidden" name="create" value="true">
				<input type="submit" value="Submit" class="btn btn-default">
			</form>
		</div>
	</div>

	<?php 
    end_template();
    exit;
}
Exemplo n.º 5
0
require_once "includes/log.php";
require_once "includes/db_connect.php";
// Start a session.
session_start();
//*****************************************************************************
/** Functions **/
//*****************************************************************************
//*****************************************************************************
/** Main Routine **/
//*****************************************************************************
// Check that the user is logged in.
if (!is_logged_in()) {
    header("Location: signin.php");
}
// start the template
start_template(array("css/deckList.css"));
// First section: User statistics
?>


<div class="container-fluid bg-1">
  <center><h2>Select A Deck</h2></center>
</div>

<div id="deckList">
	<table class="table">
	<?php 
//Get database connection
$dbc = db_connect();
if ($dbc == false) {
    echo 'Error: unable to connect to user database.';