Jump to content

php ordering


pranshu82202

Recommended Posts

I have a code

 

<?php
include('dbcon.php');
$sql = mysql_query("select * from money ORDER BY sno DESC "); 
$num=mysql_num_rows($sql);
$snumb=0;
echo '<form method="post" action="edit.php?action=trunc">';
echo '<input type="submit" value="TRUNCATE TEABLE">';
echo '</form>';

echo '<form method="post" action="del_mul.php">';

echo "<table border='1' id=hor-minimalist-a style=width:1200px>
<tr>
<th> S No. </th>
<th> Act. ID </th>
<th>Jisne Diye</th>
<th>Kisko diye</th>
<th>Kitne Diye </th>
<th>Wajah </th>
<th>Kisne bhare iss site main </th>
<th>Kiss time pe </th>
<th>Delete Entry</th>
<th>Sel for Operation</th>


</tr>";

while($row = mysql_fetch_array($sql))
{
++$snumb;
echo "<tr>";
  echo "<td>" . $snumb. "</td>";
  echo "<td>" . $row['sno'] . "</td>";
  echo "<td>" . $row['name1'] . "</td>";
  echo "<td>" . $row['name2'] . "</td>";
  echo "<td>" . $row['amm'] . "</td>";
  echo "<td>" . $row['rea'] . "</td>";
  echo "<td>" . $row['usname'] . "</td>";
  echo "<td>" . $row['time'] . "</td>";
  echo "<td><a href=edit.php?id=" . $row['sno'] . "&action=del>DELETE</a></td>";
echo '<td><input type="checkbox" name="mul_arr[]"  value='.$row[sno].'></td>';

  echo "</tr>";
}	 

echo '<input type="submit" value="DELETE SELECTED">';
echo '</form>';
?>

 

In this i thought that the "DELETE SELECTED" button should be below to the table but the button is getting printed above the Table...

 

Why is it so.......??????????????

 

And how to fix it ????????????

 

- Pranshu Agrawal

pranshu.a.11@gmail.com

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.