Hello,
I've seen loads of threads recently asking for DJ timetable things for their Dj panels.
most people probably know now anyway but, this is taken from techtuts to help you people:
DazaPHP Code:<?php
include("config.php"); // connect
if(!$_POST['post'])
{
$date = date("m/y"); // the current date ( only months and years)
echo "
<form method='post'>
Please Choose A Date Youd Like To Lookup
<p><strong>Date: *</strong>
<select name='date' id='date'>
<option>1/$date</option>
<option>2/$date</option>
<option>3/$date</option>
<option>4/$date</option>
<option>5/$date</option>
<option>6/$date</option>
<option>7/$date</option>
<option>8/$date</option>
<option>9/$date</option>
<option>10/$date</option>
<option>11/$date</option>
<option>12/$date</option>
<option>13/$date</option>
<option>14/$date</option>
<option>15/$date</option>
<option>16/$date</option>
<option>17/$date</option>
<option>14/$date</option>
<option>18/$date</option>
<option>19/$date</option>
<option>20/$date</option>
<option>21/$date</option>
<option>22/$date</option>
<option>23/$date</option>
<option>24/$date</option>
<option>25/$date</option>
<option>26/$date</option>
<option>27/$date</option>
<option>28/$date</option>
<option>29/$date</option>
<option>30/$date</option>
<option>31/$date</option>
</select><input name=\"post\" type=\"submit\" value=\"post\">
</form>";
}
else
{
$date = $_POST['date'];// get the posted date
$getdjsays = mysql_query("SELECT * FROM timetable WHERE date = '$date' ORDER BY time DESC LIMIT 24"); // selecting todays schedukle
while($r=mysql_fetch_array($getdjsays)) // put all the info into an array
{
echo "
<strong>
DJ </strong><a href=\"../members.php?user=$r[username]\" target=\"main\">
$r[username]
</a>
<strong> <br>
Show Name:</strong> $r[name]<strong><br>
Time:</strong> $r[time] <strong><br>
Date:</strong> $r[date]<br>
<strong>DJ's Comments: </strong> $r[comments]<br><br>
"; // display all the info
}
}// end code
?>


Reply With Quote
v Helpful +REP

