<div class="shortcutHome">
      <?php 
if (isset($_POST['submit'])) {
    $sin = $_POST['sin'];
    $fname = $_POST['fname'];
    $lname = $_POST['lname'];
    $address = $_POST['street'];
    $city = $_POST['city'];
    $postal = $_POST['postal'];
    $phone = $_POST['phone'];
    $gender = $_POST['gender'];
    $dob = $_POST['dob'];
    $dl = $_POST['dl'];
    include 'includes/functions.php';
    update_student($sin, $fname, $lname, $address, $city, $postal, $phone, $gender, $dob, $dl);
}
?>
    <?php 
$sin = isset($_GET['sincard']) ? $_GET['sincard'] : null;
if ($sin) {
    include 'includes/connect.php';
    $sqls = mysqli_query($dbhandle, "SELECT people.sincard, people.address,people.city,people.postal, people.first_name,people.last_name,student.dl_number,people.phone_num,people.date_birth,people.gender FROM PEOPLE  join student on student.sincard=people.sincard WHERE student.sincard='{$sin}'");
    $sqlr = mysqli_num_rows($sqls);
    $sqlf = mysqli_fetch_assoc($sqls);
    ?>


  </div>

    <table width="95%">
<?php

require_once './function.php';
update_student($_POST);
    redirect_to("update_student_id_details.php");
}
//echo "iambatman".$_SESSION['student']['student_id'];
if (isset($_POST['submit'])) {
    $dbc = dbConnect('local');
    // print_r($_POST);
    $_POST['student_id'] = $_SESSION['student']['student_id'];
    $values['ID #'] = $_POST['student_id'];
    $values['Last'] = $_POST['last_name'];
    $values['First'] = $_POST['first_name'];
    $values['Advisor'] = $_POST['advisor'];
    $values['startsem'] = $_POST['start_semester'];
    $values['startyear'] = $_POST['start_year'];
    $values['Option'] = $_POST['major'];
    //print_r($values);
    $result = update_student($values);
    if ($result == 1) {
        //echo " this is sparttaaaa ";
        //$_SESSION['student']=$_POST;
        $_SESSION['student'] = $_POST;
        redirect_to("update_student_foundation.php");
    } else {
        $error = "Student data enter failed";
    }
}
?>

<div id="page" class="container">
<div id="add_student_wrapper">
<div id="add_student_title">
<h1>
示例#4
0
require '../core/init.php';
if (!logged_in()) {
    header('Location: ../');
}
$userName = $user_data['userName'];
if (!empty($_POST['submit'])) {
    if (!empty($_POST['password']) and !empty($_POST['firstname']) and !empty($_POST['firstname']) and !empty($_POST['email']) and !empty($_POST['department'])) {
        $password = $_POST['password'];
        $repassword = $_POST['repassword'];
        if ($password = $repassword) {
            $firstname = $_POST['firstname'];
            $lastname = $_POST['lastname'];
            $email = $_POST['email'];
            $department = $_POST['department'];
            update_student($userName, $firstname, $lastname, $email, $department, $password);
            update_flag($userName, "1");
            header('Location: .');
        } else {
            $errors[] = "Password don't match";
        }
    } else {
        $errors[] = "Fields marked with an asterick are required.";
    }
}
?>


<!DOCTYPE html>
<html lang="en" class="no-js"> 
    <head>
示例#5
0
    if (!file_exists($_FILES['photo']['tmp_name']) || !is_uploaded_file($_FILES['photo']['tmp_name'])) {
        update_student($fName, $mName, $lName, $course, $yr, $id);
        $message = "<div class = 'alert alert-success' style = 'width: 350px;'>Student record has been successfully updated.</div>";
        echo "<script>";
        //go back to viewMed page after 3 seconds.
        echo "setTimeout(function(){ document.location = '?p=viewStudent'; }, 2000);";
        echo "</script>";
    } else {
        if ($photo && !$photo['error']) {
            $name = $photo['name'];
            $type = $photo['type'];
            $path = $photo['tmp_name'];
            $bytes = file_get_contents($path);
            $user = $_SESSION['user'];
            update_photo($name, $type, $bytes, $user, $id);
            update_student($fName, $mName, $lName, $course, $yr, $id);
            $message = "<div class = 'alert alert-success' style = 'width: 350px;'>{$fName} {$mName} {$lName} record has been successfully updated.</div>";
            echo "<script>";
            //go back to viewMed page after 3 seconds.
            echo "setTimeout(function(){ document.location = '?p=viewStudent'; }, 2000);";
            echo "</script>";
        } else {
            $message = "<div class = 'alert alert-warning' style = 'width: 350px;'>Invalid File.</div>";
        }
    }
} else {
    //if not submitted we retrieve the data from the database
    $studentFind = find_student($id);
    if ($studentFind) {
        $fName = $studentFind['STUDFNAME'];
        $mName = $studentFind['STUDMNAME'];
示例#6
0
    $usem3 = $_POST['sem3'];
    $usem4 = $_POST['sem4'];
    $usem5 = $_POST['sem5'];
    $usem6 = $_POST['sem6'];
    $udeadkt = $_POST['deadkt'];
    $ulivekt = $_POST['livekt'];
    $uaddr = $_POST['addr'];
    $ubday = $_POST['DOBDay'];
    $ubyr = $_POST['DOBYear'];
    $ubmonth = $_POST['DOBMonth'];
    $uemail = $_POST['email'];
    $ubranch = $_POST['branch'];
    $umob = $_POST['mob'];
    $uroll = $_POST['roll'];
    require_once 'includes/sql.php';
    $msg1 = update_student($uroll, $uemail, $umob, $ubmonth, $ubday, $ubyr, $uaddr, $ubranch);
    $msg2 = update_placement($uroll, $usscyr, $usscm, $uhscyr, $uhscm, $usem1, $usem2, $usem3, $usem4, $usem5, $usem6, $udeadkt, $ulivekt);
}
if (isset($_FILES['file'])) {
    $location = 'files_data/uploads/placement/resume/' . $ubranch . '/' . $user_info['roll_no'] . '.pdf';
    //unlink($location);
    $name = $_FILES['file']['name'];
    //$size = $_FILES['file']['size'];
    $type = $_FILES['file']['type'];
    $tmp_name = $_FILES['file']['tmp_name'];
    //$error = $_FILES[''][''];
    if (isset($name)) {
        if (!empty($name)) {
            move_uploaded_file($tmp_name, $location);
        }
    }