⚠ In case you've missed it we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This forum is read-only and soon will be archived. ⚠

callback_insert not working

callback insert bootstrap

  • Please log in to reply
1 reply to this topic

#1 Allan Alvarez Ortiz

Allan Alvarez Ortiz


  • Members
  • Pip
  • 4 posts

Posted 27 July 2015 - 11:32 PM

Hi i'm having a problem with grocery crud, i want to use the callback_insert to create some rules on the insert but its not working not even by doing nothing i mean setting the callback_insert like this:


and the funtion like this:

function insert($post_array) {
      return $this->db->insert('archivo',$post_array);

it keep giving me in google chrome console:

POST http://localhost/agenda/index.php/backend/archivo/insert 500 (Internal Server Error)

#2 Paul Savostin

Paul Savostin

    Advanced Member

  • Members
  • PipPipPip
  • 229 posts

Posted 28 July 2015 - 12:39 PM

Hi! In order to add some rules like validation you can use ->set_rules with custom callback function

For help it better write here

1) all code function and callback function code

2) Maybe database shema of table

3) Maybe write what logic u want implement before insert



Then I could help you!

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users