Server IP : 10.111.20.6  /  Your IP : 216.73.217.121
Web Server : Apache
System : Linux webm006.cluster111.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User : edizioni ( 7252)
PHP Version : 8.3.23
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0705) :  /home/edizioni/stampaeweb/../.config/../momentiribera/../extonymask/book/../

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/edizioni/stampaeweb/../.config/../momentiribera/../extonymask/book/../ex-cale.php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>
  <title>Circolo Tennis Ribera - Calendario</title>
<link rel="stylesheet" href="classifica.css">
<link rel="stylesheet" href=css/simplex.css>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.7.2/css/all.min.css">
<style>
    td, th{
        border:1px solid #111222;
        text-align:center;
    }
    th{
        background-color: lime;
    }
    td {
        font-size:.8em;
    }
</style>
<?php         include_once('mysql-fix.php');
        require_once("support/funformat.php");   include('funzioni.php');
         $dbhost1 = "edizionitonym4sk.mysql.db"; $dbname1 = "edizionitonym4sk"; $dbuser1 = "edizionitonym4sk";    $dbpass1 = "Didier0533";
         $conn1 = mysql_connect($dbhost1,$dbuser1,$dbpass1)
               or die("Impossibile collegarsi al server MySQL.");
         mysql_select_db($dbname1,$conn1)
               or die("Impossibile selezionare il database $dbname"); ?>
</head>

<body>
 <div class="ranking-title"><img src="imgtennisti/logosito.png" style="width:80px"></div>
<?php
  $nomi = array('dom','lun','mar','mer','gio','ven','sab', 'dom');
    $d_ex=explode("-", date("Y-m-d"));
    $d_ts=mktime(0,0,0,$d_ex[1],$d_ex[2],$d_ex[0]);
    $num_gg[1]=(int)date("N",$d_ts); //1 (for Monday) through 7 (for Sunday)
    $num_gg[2]= $num_gg[1] +1; if ($num_gg[2]>7) {$num_gg[2]=1;}
    $num_gg[3]= $num_gg[2] +1; if ($num_gg[3]>7) {$num_gg[3]=1;}
    $num_gg[4]= $num_gg[3] +1; if ($num_gg[4]>7) {$num_gg[4]=1;}

$oggi=date("Y-m-d"); $giorno[1] = date("l");
//$lunedi = date("d/m/y",strtotime("last Monday"));
$orari =array("07.00","08.00","09.00","10.00","11.00","12.00","13.00","14.00","15.00","16.00","17.00","18.00","19.00","20.00", "21.00");
/*if ($giorno=="Monday"){
    $lunedi = $oggi;
} */

$g[1] = $oggi;  $alfa = strtotime($g[1]);
$g[2] = $alfa + 86400; $g[2] = date("Y-m-d", $g[2]);
$g[3] = $alfa + 86400*2; $g[3] = date("Y-m-d", $g[3]);
$g[4] = $alfa + 86400*3; $g[4] = date("Y-m-d", $g[4]);
$g[1] = substr($g[1],8,2) ."-" .substr($g[1],5,2) ."-" .substr($g[1],0,4);
$g[2] = substr($g[2],8,2) ."-" .substr($g[2],5,2) ."-" .substr($g[2],0,4);
$g[3] = substr($g[3],8,2) ."-" .substr($g[3],5,2) ."-" .substr($g[3],0,4);
$g[4] = substr($g[4],8,2) ."-" .substr($g[4],5,2) ."-" .substr($g[4],0,4);
?>
<table style="border:1px solid #000; width:100%">
    <tr>
        <th rowspan="3" width="8%">#</th>
            <th colspan="2" width="23%"><?php echo $nomi[$num_gg[1]];?></th>
            <th colspan="2" width="23%"><?php echo $nomi[$num_gg[2]];?></th>
            <th colspan="2" width="23%"><?php echo $nomi[$num_gg[3]];?></th>
            <th colspan="2" width="23%"><?php echo $nomi[$num_gg[4]];?></th>
    </tr>
    <tr>

        <?php
            $ip = $_SERVER['REMOTE_ADDR'];
            $vuoto="<i class=\"fa fa-pencil\" style=\"font-size:8px\"></i>";
            for ($k=1; $k<=4;$k++){
                echo "<th colspan=\"2\">" .$g[$k] ."</th>";
            }
        ?>
    </tr>
    <tr>
      <th width="11%" style="color:#f7edc6; background-color:#333333">Campo 1</th><th width="11%" style="color:#f2dbb3;background-color:#333333">Campo 2</th>
      <th width="11%" style="color:#f7edc6; background-color:#333333">Campo 1</th><th width="11%" style="color:#f2dbb3;background-color:#333333">Campo 2</th>
      <th width="11%" style="color:#f7edc6; background-color:#333333">Campo 1</th><th width="11%" style="color:#f2dbb3;background-color:#333333">Campo 2</th>
      <th width="11%" style="color:#f7edc6; background-color:#333333">Campo 1</th><th width="11%" style="color:#f2dbb3;background-color:#333333">Campo 2</th>
    </tr>
    <?php
        for ($w=1; $w<count($orari);$w++){
            echo "<tr><td>" .$orari[$w] ."</td>";
            for ($p=1; $p<=4; $p++){
                    $cc = substr($g[$p],6,4) ."-" .substr($g[$p],3,2) ."-" .substr($g[$p],0,2);
                    $sql = "SELECT * FROM circolo_orari WHERE damo = '$cc' AND orario=$w AND campo=1";
                    $result = mysql_query($sql,$conn1); $riga=mysql_fetch_array($result);
                        $match= $riga['testo'];  $tipo= $riga['tipo'];

                        $id =$riga['id']; $cancella = "cancella.php?id=" .$id;

                        if (trim($match=='')){  // campo libero
                            $match="<a href=\"prenota.php?ora=$w&damo=$cc&campo=1\" target=\"_SELF\">$vuoto</a>";
                        }elseif ($ip == $riga['ip']){
                            $match .= " <a href=$cancella target=\"_SELF\"><i class=\"fa fa-trash\"></i></a>";
                        }
                $match ="<span class=\"badge bg-info\">$tipo</span>&nbsp;&nbsp;" .$match;
                echo "<td style=\"width:11%; background-color:#f7edc6\">$match</td>";
                    $sql = "SELECT * FROM circolo_orari WHERE damo = '$cc' AND orario=$w AND campo=2";
                    $result = mysql_query($sql,$conn1); $riga=mysql_fetch_array($result);
                        $match= $riga['testo'];  $tipo= $riga['tipo'];

                    $id =$riga['id']; $cancella = "cancella.php?id=" .$id;
                        if (trim($match=='')){  // campo libero
                            $match="<a href=\"prenota.php?ora=$w&damo=$cc&campo=2\" target=\"_SELF\">$vuoto</a>";
                        }elseif ($ip == $riga['ip']){
                            $match .="<a href=$cancella target=\"_SELF\"><i class=\"fa fa-trash\"></i></a>";
                        }
                $match ="<span class=\"badge bg-info\">$tipo</span>&nbsp;&nbsp;" .$match;
                echo "<td style=\"width:11%; background-color:#f2dbb3\">$match</td>";
            }
        }
    ?>
</table>
    <address style="color:blue; font-style:italic;"># Tutti gli atleti sono pregati di rispettare l'orario indicato</address>
    <a href="https://tonymascarella.it"><i class="fa fa-copyright">TonyMask</i></a>
</body>

</html>