Jump to content

not jumping to new file


Alfraganus

Recommended Posts

when I am clicking update cart button, it should suppose to jump to new cart.php file, but instead it is doing something odd, what can cause it?

 

it is jumping to http://localhost/ecom/ecom/cart.php (I just have 1 ecom folder, not 2)

 

 

<?php
$ip=getIp();
if (isset($_POST['update_cart'])) {
foreach($_POST['remove']as $remove_id) {
$delete_product="delete from cart where p_id='$remove_id' AND ip_add='$ip'";
$run_delete=mysqli_query($con, $delete_product);
if($run_delete) {
echo "<script>window.open('cart.php','_self') </script>";
}
}
}
if (isset ($_POST['continue'])){
echo "<script>window.open('index.php','_self') </script>";
}
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...