diff options
Diffstat (limited to 'php/admin/locations.php')
-rw-r--r-- | php/admin/locations.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/php/admin/locations.php b/php/admin/locations.php index 029594e..4069452 100644 --- a/php/admin/locations.php +++ b/php/admin/locations.php @@ -11,7 +11,7 @@ require_once('../cfg/init.php'); if (!empty($_POST['add-submit'])&&!empty($_POST['location_path'])) { if (Mirror::insert_location($_POST['product_id'],$_POST['os_id'],$_POST['location_path'])) { set_msg('Location added successfully.'); - header('Location: http://'.$_SERVER['HTTP_HOST'].WEBPATH.'/admin/locations.php'); + header('Location: '.$_SERVER['HTTP_PROTO'].'://'.$_SERVER['HTTP_HOST'].WEBPATH.'/admin/locations.php'); exit; } else { set_error('Location could not be added because of an unknown error.'); @@ -26,7 +26,7 @@ if (!empty($_POST['submit'])) { if (!empty($_POST['doit'])) { if (Mirror::update_location($_POST['location_id'],$_POST['product_id'],$_POST['os_id'],$_POST['location_path'])) { set_msg('Location updated successfully.'); - header('Location: http://'.$_SERVER['HTTP_HOST'].WEBPATH.'/admin/locations.php'); + header('Location: '.$_SERVER['HTTP_PROTO'].'://'.$_SERVER['HTTP_HOST'].WEBPATH.'/admin/locations.php'); exit; } else { set_error('Location update failed.'); |