<?php
	require 'function.php';
    require 'config.php';
	
	if(ISSET($_POST['update'])){
	    $id   = $_POST['no_id'];
		$name = $_POST['nama'];
		$date = $_POST['tgl'];
		$time = $_POST['jam'];
		
		mysqli_query($koneksi, "UPDATE `comment_id` SET `nama` = '$name', `tgl` = '$date', `jam` = '$time' WHERE `no_id` = '$id'") or die(mysqli_error());

		header("location: index.php");
	}
?>