{% else-1 %}

                        
<?php

$mm = array(1 => "Январь", "Февраль", "Март", "Апрель", "Май", "Июнь", "Июль", "Август", "Сентябрь", "Октябрь", "Ноябрь", "Декабрь");

$w = array(1 => "Пн","Вт","Ср","Чт","Пт","Сб","Вс");

$m = $mm[date("n", mktime(0,0,0,date('m'),1,date('Y')))];

$g =date("Y", mktime(0,0,0,date('m'),1,date('Y')));

$fd =date('w',mktime(0,0,0,date('n'),0,date('Y')));

$week = date("w");

print "\n<table>\n<tr>\n<td colspan='7'>\n<b>\n$m\n</b>\n</td>\n</tr>\n<tr>\n" ;
for ($dn=1;$dn<=7;$dn++)
{
if ($dn==7)
print "\n<th>\n$w[$dn]\n</th>\n";
else
print "\n<td>\n$w[$dn]\n</td>\n";
}
print "\n</tr>\n<tr>\n";

$dmm = date('t',time());

$dw = 7;

$dm = $dmm+1;

$sumd = $dmm+$fd;

$ned = $sumd/$dw;

$all = ceil($ned);

$all = $all*$dw;

$razn = $dw-$fd;

$s = date("j");

$pd = 0;

for($dd=1;$dd<$dm;$dd++)
{
if (true)
{
while($pd<$fd)
{
print "\n<td>\n+\n</td>\n";
$pd++;
}
}
if ($dd == $s)
print "\n<th>\n$dd\n</th>\n";
elseif (true)
print "\n<td>\n$dd\n</td>\n";
if (($dd==$razn) || ($dd==$razn+$dw) || ($dd==$razn+$dw*2) || ($dd==$razn+$dw*3) || ($dd==$razn+$dw*4) || ($dd==$razn+$dw*5))
print "\n</tr>\n<tr>\n";
}
while($all>$sumd)
{
print "\n<td>\n+\n</td>\n";
$all--;
}
print "\n</tr>\n<tr>\n<th colspan='7'>\n$g\n</th>\n</tr>\n";
print "\n</table>\n";
/* th
{
border-collapse: collapse;
border: 1px solid gray;
background-color : black;
text-align : center;
color : #9ACD32;
width : 10px;
height : 10px;
}
td
{
border-collapse: collapse;
border: 1px solid gray;
background-color : #295723;
text-align : center;
width : 10px;
height : 10px;
color:white;
}
table
{
border-collapse: collapse;
border: 1px solid gray;
background-color : #295723;
text-align : center;
color : #000;
width : 70px;
margin: auto auto 0px 0px;
margin-left: 0px;
margin-right: 0px;
}
*/
// стилик к нему
?>
-1 20 0
Без комментариев...