<?php 
/**  * Creates fault detail data as JSON  */    
include_once 'db_functions.php';
$state = $_REQUEST["state"];
$db = new DB_Functions();     
$users = $db->getCityMaster($state);     
$a = array();     
$b = array();    
if ($users != false){         
while ($row = mysql_fetch_array($users)) 
{                     
$b["id"] = $row["id"];
$b["state"] = $row["state"];
$b["city"] = $row["city"];
$b["country"] = $row["country"];
       
array_push($a,$b);         
}         
echo json_encode($a);     
} 
?>