<?php
require_once 'sql.php';
require_once 'sessao.php';
if (isset($_GET['id'])){
$id_ = $_GET['id'];
$sql = "DELETE FROM `user_sessions` WHERE id_user='$id_'";
$query = mysql_query($sql);
header("Location: hostnames_usuario.php?id_usuario=$id_");
}else{
$sql = "DELETE FROM `user_sessions";
$query = mysql_query($sql);
header("Location: index.php");
}
?>