예제 #1
0
<?php

session_start();
global $title;
require_once 'db.php';
$title = msg('Add a Record');
if (!isset($_SESSION['wronglang'])) {
    $_SESSION['wronglang'] = array();
}
if (isset($_GET['wronglang'])) {
    $skipid = (int) $_GET['wronglang'];
    $_SESSION['wronglang'][] = $skipid;
    set_sms_status($skipid, 0);
}
// Making sure that the "data_entry" variable is in the URL to allow/disallow showing the data entry fields
$showDataEntryFields = false;
if (isset($_GET["data_entry"]) && $_GET["data_entry"] == 1) {
    $showDataEntryFields = true;
}
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<?php 
include 'header.php';
?>
	<?php 
include_once "sidebar.php";
?>
예제 #2
0
<?php

require_once 'db.php';
if (isset($_GET['junk'])) {
    set_sms_status($_GET['junk'], 3);
    header('Location: add_record.php?sms=1&junksuccess=1');
}
$person_id = create_record($_POST);
if (!empty($_FILES) && !empty($_FILES['photo']['name'])) {
    handle_upload($person_id);
}
if (isset($_POST['sneaksms'])) {
    header('Location: smsqueue.php');
}
$query_string = '?success=' . $_POST['firstname'] . '+' . $_POST['lastname'];
if (isset($_POST['fromsms'])) {
    $query_string .= '&sms=1';
}
header('Location: add_record.php' . $query_string);
//header('Location: person.php?id=' . $person_id);