<?php
require_once __DIR__."/allfunctions.php";


	$con = mysqli_connect(get_dbserver(),get_dbuser(),get_dbpassword(),get_dbname());
	$echo="";

	$country = $_GET['country'];

	if($country!="")
    {
    $strSQL = "SELECT distinct(region) FROM 2_city WHERE status='1'  AND country='".$country."'";
    $query = mysqli_query($con,$strSQL) or die (mysqli_error($con));

	while($row = mysqli_fetch_array($query ,MYSQLI_ASSOC)) {
	$echo .=  "<option ";
	$echo .= " value='".$row['region']."'>".$row['region']."</option>";
	}
 	mysqli_close($con);
	}
	echo $echo;
?>
