Line | |
---|
1 | <?php
|
---|
2 | $db = mysql_connect("localhost","scheduletest","t3stsched");
|
---|
3 | mysql_select_db('sandboxschedule', $db) or die("Could not select database");
|
---|
4 | $Gdates = $_POST['Gdate'];
|
---|
5 | $days = Date('Y-m-d',strtotime($Gdates));
|
---|
6 |
|
---|
7 | //QUERY TO DELETE THE TABLE INSIDE THE DATABASE
|
---|
8 | /*$fetch = mysql_query("SELECT * FROM schedule WHERE date(fStart)='$days'") or die(mysql_error());
|
---|
9 | while($rows = mysql_fetch_array($fetch)){
|
---|
10 | mysql_query("DELETE FROM schedule WHERE `fStart`='".$rows['fStart']."'");
|
---|
11 | } */
|
---|
12 | mysql_query("DELETE FROM schedule WHERE DATE(fStart) = '$days'");
|
---|
13 | ?>
|
---|
Note:
See
TracBrowser
for help on using the repository browser.