Advertisement
abushyk

getCities

Jan 27th, 2014
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.26 KB | None | 0 0
  1. function getCities(){
  2.     $cities=array();
  3.     $return='';
  4.     $DBC=DBC::getInstance();
  5.     $query='SELECT city_id, name FROM '.DB_PREFIX.'_city';
  6.     $stmt=$DBC->query($query);
  7.     if($stmt){
  8.         while($ar=$DBC->fetch($stmt)){
  9.             $cities[]=$ar;
  10.         }
  11.     }
  12.     return $cities;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement