Welcome Guest, Not a member yet? Register   Sign In
Applying MySQLi options to database?
#1

In PHP, exists a function `mysqli_options`, that forces options on the driver.
I would like to apply the option MYSQLI_OPT_INT_AND_FLOAT_NATIVE, so I will get from the database numbers instead of strings.

I tried to do it like this:

PHP Code:
mysqli_options($this->dbMYSQLI_OPT_INT_AND_FLOAT_NATIVEtrue); 

Unfortunately, it says 
Code:
mysqli_options() expects parameter 1 to be mysqli, object given

How can I apply MySQLi options to a database object?

*Also, where should I do it? Currently executing in MY_Model
Reply
#2

PHP Code:
mysqli_options($this->db->conn_idMYSQLI_OPT_INT_AND_FLOAT_NATIVEtrue); 
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply




Theme © iAndrew 2016 - Forum software by © MyBB