• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
uploading two files, need to set different file type for each

#2
[eluser]Aken[/eluser]
Load the library without a config, then use initialize() before each upload, and a clear() after the first one.

Code:
$this->load->library('upload');

if ( ! empty($image))
{
    $img_config = array(); // Settings here
    $this->upload->initialize($img_config);

    // Upload stuff

    $this->upload->clear();
}

if ( ! empty($document))
{
    $doc_config = array(); // Settings here
    $this->upload->initialize($doc_config);

    // Upload stuff...
}


Messages In This Thread
uploading two files, need to set different file type for each - by El Forum - 09-09-2012, 08:08 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.