Welcome Guest, Not a member yet? Register   Sign In
Mysql start-complete
#1

(This post was last modified: 12-16-2016, 03:23 AM by Marcel.)

Hi all .

could someone please tell me if this is good code for mysql.

PHP Code:
function get_cities_from_id$cityid )
 
   {
 
       $this->db->select'
          app_cities.city_id,
          app_cities.city_fr ,
          app_cities.city_zip,
          app_cities.city_latitude,
          app_cities.city_longitude' 
);
 
       $this->db->from'app_cities' );
 
       $this->db->where'city_id'$cityid );
 
       $this->db->trans_start();
 
       $this->db->trans_complete();
 
       $result $this->db->get();
 
       if $result->num_rows() > ):
 
           return $result->first_row();
 
       else:
 
           return false;
 
       endif;
 
   

thanks alot.
Reply


Messages In This Thread
Mysql start-complete - by Marcel - 12-16-2016, 02:40 AM
RE: Mysql start-complete - by Wouter60 - 12-16-2016, 03:55 AM
RE: Mysql start-complete - by Marcel - 12-16-2016, 03:57 AM



Theme © iAndrew 2016 - Forum software by © MyBB