Hello i want to use require_once inside a function but not working??? actually i have three functions in my page how can i do that.... its working out side but not inside functions ???
Any one please ????
here is my code:
<?php
//**************************************
// Page load dropdown results //
//**************************************
function getTierOne()
{
require_once('../config.php');
$provincequery="SELECT provinces.ProvinceID, provinces.ProvinceName FROM provinces WHERE ProvinceID > 0";
$result=$coon->query($provincequery); // mysqli neeeds connection while running the query
while($province = mysql_fetch_array($result))
{
echo '<option value="'.$province['ProvinceID'].'">'.$province['ProvinceName'].'</option>';
}
}