Welcome Guest, Not a member yet? Register   Sign In
model load error.
#1

[eluser]Ram Krishna[/eluser]
i am having problem in calling model function in my controller.my controller code is
Code:
<?php

class Quote extends CI_Controller {

function __construct()
{
  parent::__construct();
  $this->load->helper(array('form', 'url'));
  
}

function index()
{
  $this->load->view('request_quote_form');
}

function do_upload()
{
  $config['upload_path'] = './uploads/';
  $config['allowed_types'] = 'gif|jpg|png|doc|docx|jpeg|pdf|txt|ppt|zip|php';
  

  $this->load->library('upload', $config);

  
     $data = $this->upload->data();
        $file_name=$data['file_name'];
        $this->load->model('quote_model');
        $this->qoute_model->quote_insert($file_name);

  
}
}
?>
#2

[eluser]PhilTem[/eluser]
I don't know what error you're actually receiving, but I see that you still need to ad

Code:
$this->upload->do_upload())

before you can call

Code:
$data = $this->upload->data();

Maybe this already solves your problem Wink




Theme © iAndrew 2016 - Forum software by © MyBB