I typically use triggers to handle timestamps but I think this may work.
$data = array(
'name' => $name,
'email' => $email
);
$this->db->set('time', 'NOW()', FALSE);
$this->db->insert('mytable', $data);
More Related Contents:
- how to select only one value sql
- How to create codeigniter dynamic menu from single table
- Comma separated numeric values – PHP CodeIgniter
- CodeIgniter – foreach loop
- PHP – Change value y,n in database [closed]
- How to insert multiple rows from array using CodeIgniter framework?
- strange character encoding of stored data , old script is showing them fine new one doesn’t
- CodeIgniter: Unable to connect to your database server using the provided settings Error Message
- Find total number of results in mySQL query with offset+limit
- How can I Use Prepared Statements in CodeIgniter
- Grouping WHERE clauses in Codeigniter
- What are the differences between backtick and single quote? Can I use IF statement in a query as above?
- How to create Codeigniter language files from database?
- Trying to get property of non-object – CodeIgniter
- Codeigniter Transactions
- How to select rows where column value IS NOT NULL using CodeIgniter’s ActiveRecord?
- Escaping SQL queries in Codeigniter
- Php mysql tabs don’t output [closed]
- Update Mysql except when field not null
- How print in Jquery / Datatables [closed]
- How can I prevent SQL injection in PHP?
- jQuery Validate remote method usage to check if username already exists
- Sending email with gmail smtp with codeigniter email library
- PDO get the last ID inserted
- Warning: mysqli_connect(): (HY000/2002): No such file or directory
- How to bind parameters to a raw DB query in Laravel that’s used on a model?
- Do I really need to do mysql_close()
- Stored Procedures, MySQL and PHP
- Difference between mysql_fetch_array and mysql_fetch_row?
- Aggregated query without GROUP BY