| Current Path : /var/www/html/mmishra/indem/pks-ec/studentinfo/ |
| Current File : /var/www/html/mmishra/indem/pks-ec/studentinfo/summary.php |
<dir>
<h3><font color='#660000'></font></h3>
<?php
$tbl = 'tbl_reg';
echo "<table width='100%' border='1' style='border-collapse:collapse'>
<tr><th>Category-wise</th><th>Gender-wise</th></tr>
<tr valign='top'><td><font color='#000066'>";
$rs = mysql_query("select category,count(*) no from $tbl group by category order by no desc");
while ($o = mysql_fetch_object($rs)) {
echo ucwords($o->category) . ' -- ' . $o->no . '<dir>';
$rs1 = mysql_query("select gender,count(*) no from $tbl where category='$o->category' group by gender order by no desc");
while ($q = mysql_fetch_object($rs1)) {
echo ' '.ucwords($q->gender) . ' -- ' . $q->no . '<br>';
}
echo '</dir>';
}
echo "</font></td><td><font color='#000066'>";
$rs = mysql_query("select gender,count(*) no from $tbl group by gender order by no desc");
while ($o = mysql_fetch_object($rs)) {
echo ucwords($o->gender) . ' -- ' . $o->no;
echo '<dir>';
//$rs1 = mysql_query("select category,count(*) no from $tbl where gender='$o->gender' group by category order by no desc");
//while ($q = mysql_fetch_object($rs1)) {
// echo ucwords($q->category) . ' -- ' . $q->no . '<br>';
//}
echo '</dir>';
}
echo "<br><br><b><hr>Program-wise<hr></b>";
$rs = mysql_query("select courseName,count(*) no from $tbl group by courseName order by no desc");
while ($o = mysql_fetch_object($rs)) {
echo ucwords($o->courseName) . ' -- ' . $o->no . '<dir>';
//$rs1 = mysql_query("select gender,count(*) no from $tbl where courseName='$o->courseName' group by gender order by no desc");
//while ($q = mysql_fetch_object($rs1)) {
// echo ucwords($q->gender) . ' -- ' . $q->no . '<br>';
//}
echo '</dir>';
}
/* -----------------
echo "</font></td></tr>
<tr><th>Program-wise</th><th>State-wise</th></tr>
<tr valign='top'><td><font color='#000066'>";
$rs = mysql_query("select courseName,count(*) no from $tbl group by courseName order by no desc");
while ($o = mysql_fetch_object($rs)) {
echo ucwords($o->courseName) . ' -- ' . $o->no . '<dir>';
//$rs1 = mysql_query("select gender,count(*) no from $tbl where courseName='$o->courseName' group by gender order by no desc");
//while ($q = mysql_fetch_object($rs1)) {
// echo ucwords($q->gender) . ' -- ' . $q->no . '<br>';
//}
echo '</dir>';
}
echo "</font></td><td><font color='#000066'>";
$rs = mysql_query("select state1,count(*) no from $tbl group by state1 order by no desc");
while ($o = mysql_fetch_object($rs)) {
echo ucwords($o->state1) . ' -- ' . $o->no . '<dir>';
//$rs1 = mysql_query("select category,count(*) no from $tbl where state1='$o->state1' group by category order by no desc");
//while ($q = mysql_fetch_object($rs1)) {
// echo ucwords($q->category) . ' -- ' . $q->no . '<br>';
//}
echo '</dir>';
}
------------------- */
echo '</font></td></tr>
</table><br><br>
</dir>';
?>