<?php
	include_once('ressources/class.templates.inc');
	include_once('ressources/class.ldap.inc');
	include_once('ressources/class.users.menus.inc');
	include_once("ressources/class.os.system.inc");
	
	
	$user=new usersMenus();
	if(!$user->AsSystemAdministrator){echo "alert('no privileges');";die();}
	
	
	if(isset($_GET["popup"])){popup();exit;}
	if(isset($_POST["LogsWarninStop"])){LogsWarninStop();exit;}
	
js();


function js(){
	$page=CurrentPageName();
	$tpl=new templates();
	$title=$tpl->javascript_parse_text("{squid_logs_urgency_section}");
	echo "YahooWin5('800','$page?popup=yes','$title')";
	
}


function popup(){
	$page=CurrentPageName();
	$tpl=new templates();
	$sock=new sockets();
	$LogsWarninStop=$sock->GET_INFO("LogsWarninStop");
include_once 'ressources/class.templates.inc';
include_once 'ressources/class.ldap.inc';
include_once 'ressources/class.users.menus.inc';
include_once "ressources/class.os.system.inc";
$user = new usersMenus();
if (!$user->AsSystemAdministrator) {
    echo "alert('no privileges');";
    die;
}
if (isset($_GET["popup"])) {
    popup();
    exit;
}
if (isset($_POST["LogsWarninStop"])) {
    LogsWarninStop();
    exit;
}
js();
function js()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $title = $tpl->javascript_parse_text("{squid_logs_urgency_section}");
    echo "YahooWin5('800','{$page}?popup=yes','{$title}')";
}
function popup()
{
    $page = CurrentPageName();
    $tpl = new templates();
    $sock = new sockets();