0

I have two tables in one form and a button in another form. So the two tables must be displayed first and then the button. But for me the button is displayed between the two tables. Can anyone help me??

This is my code

<form action="choirEvedit.php5" method="post">
<?php

$con = mysql_connect("localhost","root","");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }
  mysql_select_db("centreformusic", $con);
   $res=mysql_query("select * from choirevent where ProgId='$_GET[pid]' and event_date='$_GET[dt]'") or die(mysql_error());
        echo "Events<br><br>";
        echo "<input type='hidden' name='pid' value='$_GET[pid]'>";
        echo "<table border='0' cellpadding='3' cellspacing='3' class='name'>";
        echo "<tr><th>Event Date:</th><th>Time:</th><th>Title:</th></tr>";
        while($row=mysql_fetch_array($res))
        {   
          
           echo "<tr><td><a href='choirEved.php5?pid=".$row[ProgId]."&dt=".$row[event_date]."'>".$row[event_date]."</a></td>";
           echo "<td>".$row[Time]."</td>";
           echo "<td>".$row[title]."</td></tr>"; 
        }
        echo "</table>";
  $sql=mysql_query("select * from song where ProgId='$_GET[pid]'") or die(mysql_error());
   echo "<table border='0' cellpadding='3' cellspacing='3' class='name'>";   
   $count=0;
   echo "<tr><th>S.No.</th><th>Song</th><th>Author</th>";
   while($row=mysql_fetch_array($sql))
   {
       $count=$count+1;
       echo "<tr><td><a href='choirEvSong.php5?pid=".$row[ProgId]."&sid=".$row[SongID]."'>$count</a></td>";
       echo "<td>".$row[Song]."</td>";
       echo "<td>".$row[Author]."</td></tr>";
   }
  
mysql_close($con);
?>
</form>
<form action="choirEvent1.php5" method="post">
<input type="image" src="images/back.png">
</form>
2
Contributors
1
Reply
2
Views
5 Years
Discussion Span
Last Post by whiteyoh
0

check to see if <div style="clear:both"> or something similar works OR just make sure you have finished the table off correctly with </table>

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.