<head>
<title></title>
<style type="text/css">
h1 {font-size: 35px; font-family: calibri; color:black}
h2 {font-size: 20px; font-family: courier; color:white}
text {font-size: 17px; font-family: calibri; color:black;}
p {font-size: 15px; font-family: century gothic}
#blueborder {
-moz-border-radius: 30px;
border-radius: 30px;
}
</style>
</head>
<body style="background: #b8e1fc; /* Old browsers */
background: -moz-linear-gradient(top, #b8e1fc 0%, #a9d2f3 10%, #90bae4 25%, #90bcea 37%, #90bff0 50%, #bdf3fd 95%, #6ba8e5 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#b8e1fc), color-stop(10%,#a9d2f3), color-stop(25%,#90bae4), color-stop(37%,#90bcea), color-stop(50%,#90bff0), color-stop(95%,#bdf3fd), color-stop(100%,#6ba8e5)); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, #b8e1fc 0%,#a9d2f3 10%,#90bae4 25%,#90bcea 37%,#90bff0 50%,#bdf3fd 95%,#6ba8e5 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, #b8e1fc 0%,#a9d2f3 10%,#90bae4 25%,#90bcea 37%,#90bff0 50%,#bdf3fd 95%,#6ba8e5 100%); /* Opera11.10+ */
background: -ms-linear-gradient(top, #b8e1fc 0%,#a9d2f3 10%,#90bae4 25%,#90bcea 37%,#90bff0 50%,#bdf3fd 95%,#6ba8e5 100%); /* IE10+ */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#b8e1fc', endColorstr='#6ba8e5',GradientType=0 ); /* IE6-9 */
background: linear-gradient(top, #b8e1fc 0%,#a9d2f3 10%,#90bae4 25%,#90bcea 37%,#90bff0 50%,#bdf3fd 95%,#6ba8e5 100%); /* W3C */"</body>
<?php
include("connect.php");
echo '<form method="POST">';
$res = mysql_query ("SELECT DISTINCT date FROM q WHERE date < DATE(NOW()) ORDER by id");
while($row = mysql_fetch_array($res))
{
echo '<input type="submit" value='.$row['date'].' name="dato">';
}
echo '</form>';
?>
<div id="blueborder" style="width:600px;border:3px solid blue;margin: 0 auto;" />
<?php
if($_POST['dato'])
{
echo '<center><h2>'.$_POST['dato'].'</h2></center>';
$eres = mysql_query ("SELECT * FROM q WHERE date = $_POST['dato'] ");
$erow = mysql_fetch_array($eres);
$text = $row['text'];
echo $text;
}
?>