<?php SESSION_START();
if(!isset($_SESSION['admin_id'])){
	header("location: ../index.php");
}
?>
<?php  include("../config/config.php");?>
<?php
	
	
	$id = $_POST['id'];
	$title = addslashes($_POST['title']);
	$author = $_POST['author'];
	$publisher = $_POST['publisher'];
	$status = $_POST['status'];
	$isbn = $_POST['isbn'];
	$call_no = $_POST['call_no'];	
	$copyright = $_POST['copyright'];	
	$subClass = $_POST['subClass'];	
	$Class = $_POST['Class'];	
	$section = $_POST['section'];	
	
	
	mysql_query("UPDATE books SET 
	title = '$title',
	author = '$author',
	publisher_name = '$publisher',
	status = '$status', 
	call_number = '$call_no',
	isbn_no = '$isbn',
	copyright_year ='$copyright',
	subclass_1 ='$Class',
	section ='$section',
	subclass_2 ='$subClass'

	WHERE accession_no= '$id'") or die(mysql_error());
		
?>

<div class="success">Update Complete<div>