<?php
include('../include/connection.php');
$sql = "select d.id,d.name from localgovt l inner join discos d on l.disco_id=d.id where l.id=:id";
$q=$con->select_query($sql,array(':id'=>$_GET['lga']));
{
    foreach($q as $r)
    {
        echo '<option value="'.$r['id'].'">'.$r['name'].'</option>';
    }
}
/*$sql = "select ds.disco_id,d.name from disco_state ds inner join discos d on ds.disco_id=d.id where ds.state_id=:id";
$q=$con->select_query($sql,array(':id'=>$_GET['state']));
{
    foreach($q as $r)
    {
        echo '<option value="'.$r['disco_id'].'">'.$r['name'].'</option>';
    }
}*/
?>