Here is the generic CodeIgniter model function which you can be used to both update and insert data into the database. The function checks primary key validation automatically so it will update the contents if primary key already exists else it will perform insert query. Th...
Read More