<?php
//DB Data
include '../../ASEngine/AS.php';
if(!$login->isLoggedIn())
    header("Location: ../../login.php");
$user = new ASUser(ASSession::get("user_id"));
$userInfo = $user->getInfo();

//basic include files
require_once("../../../db.php");

//variables
$hotel_id = $_GET['hotelid'];
$hotel_name = $_GET['hotelname'];
$photo_id = $_GET['photoid'];
$photo_status = $_GET['photostatus'];

mysqli_query($conn, "UPDATE hotel_images SET hotel_ima_active = '$photo_status' WHERE hotel_image_id = '$photo_id' ");

mysqli_close($conn);

header("Location: ../../manage-hotel.php?hotelid=".$hotel_id."&hotelname=".$hotel_name."&hotelmsn=p".$photo_status."&tab=4");
?>