[eluser]PHP Programmer[/eluser]
After that, I did the following in controller:
$config['upload_path'] = './uploads/Employer/Photo/';
$config['allowed_types'] = 'gif|jpg|png';
$config['max_size'] = '2048'; //2 meg
$this->load->library('upload', $config);
foreach($_FILES as $key => $value)
{
//print_r($value);
if( ! empty($key))
{
$this->upload->initialize($config);
if ( ! $this->upload->do_upload($key))
{
echo "here";
print_r($errors[] = $this->upload->display_errors());
}
else
{
echo "this";
$data = array('upload_data' => $this->upload->data());
//$this->Process_image->process_pic();
}
}
}
And, it always goes in error message. How to resolve this??