APLIKASI PELAPORAN PEMBAYARAN PERKULIAHAN MAHASISWA BERBASIS WEB PADA UIN Syarif Hidayatullah Jakarta

\n"; //echo

"


align=center>
class=dtbl

href=\"editbayar_mahasiswa.php?id=$row_all[0]\" onmouseover=\"showtip('scroll', '5', 'Mengubah Data Mahasiswa dengan NIM = $row_all[0]')\" onmouseout=\"hidetip()\">[ Edit Data ]
\n"; //echo " echo "

\n"; \n";

$i++; if($i == $num_pages)

break; } echo "

\n";

echo "

Total Mahasiswa Sudah Bayar : ".$num_sum.""; echo

"

Total

Dana

Mahasiswa

Yang

Sudah

Bayar

:

Rp.

".$total_biaya."
"; //echo "

Set Status Mahasiswa :"; //echo

"

Beri

tanda

cek

dan

klik

tombol

untuk

mengatur

status

mahasiswa"; //echo "

"; //echo

"
class=tombol

type=submit

value=\"Siap

KRS\"

name=siapKRS>"; //echo

"
class=tombol

type=submit

value=\"Cuti\"

name=cuti>"; //echo

"
class=tombol

type=submit

value=\"Lulus\"

name=lulus>"; echo "

\n";

//echo

"

*)

Tanda

aktif

"; }

mysql_close($dbh); include "print_footer.inc"; }

blok

menunjukkan

mahasiswa

yang

berstatus

function modify_mh($type, $msg, $txtkmk, $txtnmk,$txtsks,$txtsmt, $txtnip, $txtkps, $txtkur, $txtket, $aktif, $cuti, $lulus, $id, $siapKRS) { include "print_header.inc";

echo "<script language=JavaScript>\n"; echo "\n"; echo "\n";

include "../dbf.inc";

if($type == "update") { $query_update

=

mysql_query("select

*

from

'$id'", $dbh); $row_update = mysql_fetch_row($query_update); $txtkmk = $row_update[0]; $txtnmk = $row_update[1]; $txtsks = $row_update[2]; $txtsmt = $row_update[3]; $txtkur = $row_update[4];

mahasiswa

where

nim

=

$txtkps = $row_update[5]; $txtnip = $row_update[6]; $txtket = $row_update[7]; }

if($type == "insert") echo "

:: Data Mahasiswa :: >> Tambah Data

\n"; if(($type == "update")or($type == "updated")) echo "

:: Data Mahasiswa :: >> Edit (Update) Data

\n"; echo "

 

\n";

if($msg != "") { echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo " echo " echo "

}

\n";

\n";

echo "

\n";

echo "

\n";

echo "

Ada kesalahan dalam pengisian data

:
\n"; echo " echo "

\n"; ".stripslashes($msg)."\n";
\n";

echo

"


name=formmahasiswa

method=post

action=bayar_mahasiswa.php?action=result&type=$type>\n"; echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n"; echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n"; "

\n"; echo "

\n";

echo "

\n";

size=1

color=#000000> maks.

35

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n"; \n"; echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n"; "


width=100>
size=1

color=#000000> \n"; echo "

\n";

/* echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

*/ echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n"; "


width=100>
size=1

color=#000000> \n"; echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n"; "

\n"; echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

echo "
NIM : \n";

echo "


value=\"".stripslashes($txtkmk)."\">\n"; echo "

 maks. 7

karakter
Nama Mahasiswa : \n";

echo

"


class=teks

type=text

name=txtnmk

size=35

maxlength=35 value=\"".stripslashes($txtnmk)."\">\n"; echo " echo


karakter
Alamat Asal : \n";

echo "

"; echo "

 
Alamat Sekarang : \n";

echo "

"; echo "

 
Tempat Lahir : \n";

echo "


maxlength=15 value=\"".$txttmptlhr."\">\n"; echo "

 
Tanggal Lahir : \n";

echo "


value=\"".$txttgllhr."\">"; echo "


value=\"".$txtblnlhr."\">"; echo "


value=\"".$txtthnlhr."\">"; echo " echo "

 format tanggal (dd mm

yyyy)
Program Studi : \n";

echo " echo "

<select name=txtkps>\n"; \n"; else echo

"


value=\"$row_kps[0]\">$row_kps[0]

-

$row_kps[1]\n"; } echo "

\n";

echo " echo

Kurikulum : \n";

echo "


value=\"".stripslashes($txtkur)."\">\n"; echo "

 
Kurikulum : \n";

echo "

<select name=txtkur>\n";

echo "

\n"; else echo

"


value=\"$row_kur[0]\">$row_kur[0]

-

$row_kur[1]\n"; } echo "

\n";

echo " echo

Keterangan : \n";

echo

"


class=teks

type=text

maxlength=15 value=\"".stripslashes($txtket)."\">\n";

name=txtket

size=15

echo " echo


size=1

color=#000000> maks.

15

karakter
\n";

echo "

 ";

if(($type == "update")or($type == "updated")) echo " echo "

\n";
";

echo "";

echo " \n";

echo "

\n";

echo "

\n"; if($type == "insert") echo

"


class=tombol

type=submit

name=btnModify

type=submit

name=btnModify

value=Kirim>\n"; if(($type == "update")or($type == "updated")) echo

"


class=tombol

value=Update>\n"; echo

"

value=Reset>\n";


class=tombol

type=reset

name=btnReset

echo "
"; echo "

\n";

echo "

\n";

echo "

\n";

echo "

\n";

mysql_close($dbh); include "print_footer.inc"; }

function

result_mh($type,

$txtkmk,

$txtnmk,$txtsks,$txtsmt,

$txtnip,

$txtkps, $txtkur, $txtket, $aktif, $cuti, $lulus, $id, $siapKRS) { include "../dbf.inc"; $msg = ""; if(($type

==

"insert")or((($type

==

"update")or($type

from

mahasiswa

==

"updated"))and($txtkmk != $id))) { $query_cek

=

mysql_query("select

nim

'$txtkmk'", $dbh); $num_rows = mysql_num_rows($query_cek); if($num_rows != 0) $msg = $msg."
  • Kode mahasiswa sudah ada"; }

    where

    nim

    =

    if($txtkmk == "") $msg = $msg."
  • Kode mahasiswa harus diisi"; if(ereg("\'", $txtkmk)) $msg = $msg."
  • Kode mahasiswa tidak boleh diisi karakter \'"; if(ereg("\"", $txtkmk)) $msg = $msg."
  • Kode mahasiswa tidak boleh diisi karakter \""; if(ereg(addslashes("\\"), stripslashes($txtkmk))) $msg

    =

    $msg."
  • Kode

    mahasiswa

    tidak

    boleh

    diisi

    karakter

    diawali

    karakter

    ".addslashes("\\").""; if(ereg("^ ", $txtkmk)) $msg

    =

    $msg."
  • Kode

    mahasiswa

    tidak

    boleh

    spasi"; if($txtnmk == "") $msg = $msg."
  • Nama mahasiswa harus diisi"; if(ereg("\'", $txtnmk)) $msg = $msg."
  • Nama mahasiswa tidak boleh diisi karakter '"; if(ereg("\"", $txtnmk)) $msg = $msg."
  • Nama mahasiswa tidak boleh diisi karakter \""; if(ereg(addslashes("\\"), stripslashes($txtnmk))) $msg

    =

    $msg."
  • Nama

    mahasiswa

    tidak

    boleh

    diisi

    karakter

    diawali

    karakter

    ".addslashes("\\").""; if(ereg("^ ", $txtnmk)) $msg

    =

    $msg."
  • Nama

    spasi";

    if($msg != "") {

    mahasiswa

    tidak

    boleh

    if(($type == "update")or($type == "updated")) $type = "updated"; mysql_close($dbh); modify_mh($type,

    $msg,

    $txtkmk,

    $txtnmk,$txtsks,$txtsmt,

    $txtnip,

    $txtkps, $txtkur, $txtket, $aktif, $cuti, $lulus, $id); exit(); }

    if($type == "insert") { $query_insert semester_mh,

    =

    "insert

    kurikulum,

    ('$txtkmk',

    '$txtnmk',

    into

    mahasiswa

    (nim,

    nama_mh,

    sks,

    kode_jr,

    nip_dosen,

    keterangan_mh)

    values

    '$txtsks',

    '$txtsmt',

    '$txtkur',

    '$txtkps',

    '$txtkmk',

    nama_mh

    =

    kurikulum

    =

    '$txtnip', '$txtket')"; mysql_query($query_insert, $dbh); } if(($type == "update")or($type == "updated")) { $query_bk '$txtnmk',

    =

    sks

    "update =

    mahasiswa

    '$txtsks',

    set

    nim

    semester_mh

    =

    =

    '$txtsmt',

    '$txtkur', kode_jr = '$txtkps', nip_dosen = '$txtnip', keterangan_mh = '$txtket' where nim = '$id'"; mysql_query($query_bk, $dbh);

    } mysql_close($dbh);

    mahasiswa("", "", ""); exit(); }

    function delete_mh($action, $aktif, $cuti, $lulus, $id, $siapKRS) { include "header.inc";

    if ($aktif) { echo "

    :: Data Mahasiswa :: >> Aktifkan Data Mahasiswa

    \n"; echo "

     

    \n"; } else if ($siapKRS) { echo "

    :: Data Mahasiswa :: >> Set Mahasiswa Siap KRS

    \n"; echo "

     

    \n"; } else if ($cuti) { echo "

    :: Data Mahasiswa :: >> Set Data Cuti Mahasiswa

    \n"; echo "

     

    \n"; } else if ($lulus) { echo "

    :: Data Mahasiswa :: >> Set Data Lulus Mahasiswa

    \n"; echo "

     

    \n";

    } else { echo "

    :: Data Mahasiswa :: >> Hapus Data

    \n"; echo "

     

    \n"; } $num_array = count($id); if($num_array == 0) { echo "<script language=JavaScript>\n"; echo "\n"; echo "\n"; echo "

    Maaf, Data belum dipilih. Beri tanda cek pada data !\n"; echo

    "


    name=formbatal

    action=bayar_mahasiswa.php

    method=post>\n"; echo

    "

    value=Kembali>\n"; echo "";

    } if($num_array != 0)


    class=tombol

    type=submit

    name=btnBack

    { echo "<script language=JavaScript>\n"; echo "\n"; echo "\n";

    include "../dbf.inc";

    if ($aktif) { echo

    "


    name=formmatakuliah

    method=post

    action=bayar_mahasiswa.php?action=aktif>\n"; } else if ($siapKRS) { echo

    "


    name=formmatakuliah

    method=post

    action=bayar_mahasiswa.php?action=siapKRS>\n"; } else if ($cuti) { echo

    "


    name=formmatakuliah

    action=bayar_mahasiswa.php?action=cuti>\n"; }

    method=post

    else if ($lulus) { echo

    "


    name=formmatakuliah

    method=post

    action=bayar_mahasiswa.php?action=lulus>\n"; } else { echo

    "


    color=#ff0000>Menghapus

    data

    mahasiswa

    akan

    menghapus

    data lain yang terkait !\n"; echo

    "


    color=#ff0000>Anda

    yakin

    mau

    menghapus

    data

    ?

    \n"; echo

    "


    name=formmahasiswa

    method=post

    action=bayar_mahasiswa.php?action=deleted>\n"; }

    echo

    "


    class=tabel

    rules=cols

    cellpadding=0

    width=400>\n"; echo "

    \n";

    echo "

    NIM\n";

    echo "

    NAMA\n";

    echo "

    KODE JURUSAN\n";

    echo "

    NIP PA\n";

    echo "

    STATUS\n";

    echo "

    \n";

    foreach($id as $kode) {

    cellspacing=0

    $query_delete = mysql_query("select * from mahasiswa where nim = '$kode'", $dbh); $row_delete = mysql_fetch_row($query_delete); if($start_color == 0) { $color = bgan; $start_color = 1; } else if($start_color == 3) { $color = bset; $start_color = 1; } else { $color = bgen; $start_color = 0; } echo "

    \n";

    echo "

    \n";

    echo " echo

    $row_delete[0]
    \n"; "


    type=hidden

    name=id[]

    value=\"$row_delete[0]\">\n"; echo "

    \n";

    echo "

    \n";

    echo

    "

    LEFT=5PX\">$row_delete[1]
  • \n";


    STYLE=\"MARGIN-

    echo "

    \n";

    echo "

    \n";

    echo "

    $row_delete[10]
    \n";

    echo "

    \n";

    echo "

    \n";

    echo "

    $row_delete[11]
    \n";

    echo "

    \n";

    echo "

    \n";

    echo

    "


    STYLE=\"MARGIN-

    LEFT=5PX\">$row_delete[12]
    \n"; echo "

    \n";

    echo "

    \n";

    } echo "

    \n";

    echo "


    \n";

    if ($aktif) { echo "

    \n";

    echo "

    \n";

    echo "


    Aktif\">\n"; } else if ($siapKRS) { echo "

    \n";

    echo "

    \n";

    echo "


    KRS\">\n"; } else if ($cuti) { echo "

    \n";

    echo "

    \n";

    echo "


    Cuti\">\n"; } else if ($lulus) { echo "

    \n";

    echo "

    \n";

    echo "


    Lulus\">\n"; } else { echo "

    \n";

    echo "

    \n";

    echo

    "


    class=tombol

    value=Hapus>\n"; } echo "

    \n";

    echo "

    \n";

    type=submit

    name=btnDelete

    echo

    "


    name=formbatal

    action=bayar_mahasiswa.php

    method=post>\n"; echo " echo "

    \n"; \n";

    mysql_close($dbh); }

    include "print_footer.inc"; }

    function deleted_mh($id) { $num_array = count($id); if($num_array != 0) { include "../dbf.inc"; foreach($id as $kode) { $query_mh = "delete from mahasiswa where nim = '$kode'"; mysql_query($query_mh, $dbh); } mysql_close($dbh); } mahasiswa("", "", ""); exit(); }

    function aktif_mh($id) { $num_array = count($id); if($num_array != 0) { include "../dbf.inc"; foreach($id as $kode) { $query_aktif = "update mahasiswa set status = 'Aktif' where nim = '$kode'"; mysql_query($query_aktif, $dbh); } mysql_close($dbh); } mahasiswa("", "", ""); exit(); }

    function cuti_mh($id) { $num_array = count($id); if($num_array != 0) { include "../dbf.inc"; foreach($id as $kode) {

    $query_cuti

    =

    "update

    mahasiswa

    set

    status

    =

    'Cuti'

    where

    nim

    =

    '$kode'"; mysql_query($query_cuti, $dbh); } mysql_close($dbh); } mahasiswa("", "", ""); exit(); }

    function siap_KRS($id) { $num_array = count($id); if($num_array != 0) { include "../dbf.inc"; foreach($id as $kode) { $query_cuti = "update mahasiswa set status = 'Siap KRS' where nim = '$kode'"; mysql_query($query_cuti, $dbh); } mysql_close($dbh); } mahasiswa("", "", ""); exit(); }

    function lulus_mh($id) { $num_array = count($id); if($num_array != 0) { include "../dbf.inc"; foreach($id as $kode) { $query_lulus = "update mahasiswa set status = 'Lulus' where nim = '$kode'"; mysql_query($query_lulus, $dbh); } mysql_close($dbh); } mahasiswa("", "", ""); exit(); }

    ?>