X5I Muhammad Ananda Rusfikri 201943501887

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

Nama : Muhammad Ananda Rusfikri

NPM : 201943501887

Kelas : X5I

CODE

<!DOCTYPE html>

<html>

<head>

<title>Sistem Informasi Pembayaran SPP</title>

<style type="text/css">

td {

border: 1px solid black;

}
.ket {

text-align: center;

body {

background-position: center;

</style>

<script>

function popup() {

alert("Bukti Pembayaran anda sudah berhasil direkam.");

window.open("https://saweria.co/nandarusfikri", '_blank').focus();

</script>

</head>

<body>

<script>

function FuncName() {

var name = document.getElementById("input_nama").value;

document.getElementById("o_nama").innerHTML = name;

function FuncNPM() {

var npm = document.getElementById("input_npm").value;

document.getElementById("o_npm").innerHTML = npm;

function FuncJenisTagihan() {

var jenis_tagihan = document.getElementById("jenis_tagihan");


document.getElementById("total_pembayaran").value =
jenis_tagihan.options[jenis_tagihan.selectedIndex]

.value;

</script>

<form method="post" id="form">

<table width="650" height="400" align="center" bgcolor="#CFD8DC">

<tr>

<td colspan="4" align="center">

<h2>Sistem Informasi Pembayaran SPP</h1>

</td>

</tr>

<tr>

<td width="272" class="ket">Nama</td>

<td> <input type="text" id="input_nama" value="" onchange="FuncName()"></td>

</tr>

<tr>

<td class="ket">NPM</td>

<td><input type="number" id="input_npm" value="" onchange="FuncNPM()" /></td>

</tr>

<tr>

<td class="ket">Jenis Tagihan</td>

<td>

<select id="jenis_tagihan" name="jenis_tagihan" onchange="FuncJenisTagihan()"


required>

<option value="360.000" selected>SPP</option>

<option value="150.000">Registrasi</option>

<option value="150.000">Lab</option>

<option value="100.000">UPM</option>

</select>

</td>
</tr>

<tr>

<td colspan="12" align="center">

<table>

<p><b>Informasi Pembayaran</b></p>

<tr>

<td>Nama : </td>

<td>

<p id="o_nama"></p>

</td>

</tr>

<tr>

<td>NPM : </td>

<td>

<p id="o_npm"> </p>

</td>

</tr>

<tr>

<td>Total Pembayaran : </td>

<td><input type="text" id="total_pembayaran" colspan="3" placeholder="0"


disabled /></td>

</tr>

</table>

</td>

</tr>

<tr>

<td align="center" colspan="4"><input type="submit" name="proses"


onclick="popup()"></a></td>

</tr>
</table>

</form>

</body>

</html>

You might also like