<?php require('top.php'); if(isset($_POST['submit'])) { $catogry=mysqli_real_escape_string($conn,$_POST['Catogry']); $add_catogry="insert into categories (categories, status) VALUES ($catogry,'1')"; mysqli_query($conn,$add_catogry); header('location:catogry.php'); } ?>
<?php require('top.php'); if (isset($_GET['type']) && $_GET['type']!='') { $type=mysqli_real_escape_string($conn,$_GET['type']) ; if($type=='status') { $operation=mysqli_real_escape_string($conn,$_GET['operation']); if($operation=='active') { $status='1'; } else { $status='0'; } $id=mysqli_real_escape_string($conn,$_GET['id']); $update_status="update categories set status='$status' where id=$id"; mysqli_query($conn,$update_status); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)