| Server IP : 172.64.80.1 / Your IP : 172.70.50.62 Web Server : Apache System : Linux mail.federalpolyede.edu.ng 5.10.0-32-amd64 #1 SMP Debian 5.10.223-1 (2024-08-10) x86_64 User : federalpolyede.edu.ng_idh35skikv ( 10000) PHP Version : 7.4.33 Disable Function : opcache_get_status MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /var/www/vhosts/federalpolyede.edu.ng/httpdocs/js/ |
Upload File : |
<?php
$state=$_POST['state'];
//echo $school;
//die();
require('../connect.php');
$db=db_connect();
$query="SELECT * FROM states WHERE state='$state'";
$rs=$db->query($query);
$out='<select name="lga" class="form-control">';
while ($row = $rs->fetch (PDO::FETCH_NUM)){
//for($i=0;$i<mysql_num_rows($rs);$i++){
//$row=mysql_fetch_row($rs);
$out.='<option>'.$row[2].'</option>';
}
$out.='</select>';
echo $out;
?>