amylou Posted August 24, 2007 Share Posted August 24, 2007 when i had a delete function to this i can not get the form to show up at all. i did not post the form. I would like it to do what it does now and then have a delete button to delete the ones that the user does not want. i have tried different ways. if i have just the delete and they enter their name and the date off(which needs to be added) it will work but will not show what they have <?php function getmonth($m=0) { return (($m==0 ) ? date('F') : date('F', mktime(0,0,0,$m))); } ?> </head> <body> <br> <img src="33720001.jpg" alt="sitel" width="300" height="100" /> <?php if(isset($_POST['action'])){$action=$_POST['action'];}else{$action="";} if( $action == 'updated' ) { extract ($_POST); $todaysDate = date("Y-m-d",time()); // Need to query database to see if this request is valid echo "<p><strong>These are the dates that you have requested off!!!!</strong></p>"; $sql ="SELECT first, last, requestedDate FROM timeoff WHERE last = '$last' AND first = '$first'"; $query=mysql_query($sql) or die("Query failed : " . mysql_error()); while($row = mysql_fetch_assoc($query)) { echo "<p>"; echo $row['first'] ." ". $row['last']. " ". " ". $row['requestedDate']; echo "</p>"; } $action=""; } else { ?> Link to comment Share on other sites More sharing options...
fenway Posted August 27, 2007 Share Posted August 27, 2007 Double-post; see this thread. Link to comment Share on other sites More sharing options...
Recommended Posts