Guest User

Untitled

a guest
May 22nd, 2018
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. $sql="DELETE FROM product_types WHERE id=".$_POST['type_id'];
  2. if(!mysqli_query($conn,$sql)){
  3. echo "This type can't be deleted because it belongs to other products."; exit();
  4. }else {logging($target_name,"delete");}
  5.  
  6. $sql="DELETE FROM product_types WHERE id=".$_POST['type_id'];
  7. $result=mysqli_query($conn,$sql)
  8. if(!$result){
  9. echo "This type can't be deleted because it belongs to other products."; exit();
  10. }else {logging($target_name,"delete");}
Add Comment
Please, Sign In to add comment