Welcome Guest, Not a member yet? Register   Sign In
How to insert corporate details into database
#5

(This post was last modified: 11-18-2020, 05:04 AM by christaliise.)

(11-17-2020, 12:05 PM)InsiteFX Wrote: No, you want to do it in the controller.

Controller:

PHP Code:
$this->load->model('Afghanistancorporate_model''afghanistancorporate_model');

$corporatename $this->input->post('corporatename');
$password $this->input->post('password');
$countryterritory $this->session->userdata('country_territory'); 

$this->Afghanistancorporate_model->insert_corporate($corporatename$password$countryterritory); 

Thanks InsiteFX. I already have the first 4 lines in the Controller. If I put the fifth line in the Controller, after the variable definitions, I get error;

Message: Undefined property: Afghanistan::$Afghanistancorporate_model

Ive moved it to several different places in the Controller & tried it surrounded by curly brackets but still did not enter the corporate table.

The fifth line has been deleted from the model.

Im exhausted with ideas, other than trying again to enter it into the members table.
Reply


Messages In This Thread
RE: How to insert corporate details into database - by christaliise - 11-18-2020, 05:03 AM



Theme © iAndrew 2016 - Forum software by © MyBB