Jump to content


Multiple Upload

upload

  • Please log in to reply
7 replies to this topic

#1 mavershim

mavershim

    Advanced Member

  • Members
  • PipPipPip
  • 40 posts

Posted 22 May 2012 - 08:38 AM

hi,

is there a way to upload multiple files.

#2 web-johnny

web-johnny

    grocery CRUD Author

  • Administrators
  • 1,099 posts
  • LocationLondon

Posted 22 May 2012 - 10:24 PM

No yet. It is a future feature.
Posted Image

#3 avambro

avambro

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 13 May 2013 - 09:53 PM

 I need a solutions like that :S 



#4 likhon3k

likhon3k

    Advanced Member

  • Members
  • PipPipPip
  • 56 posts

Posted 14 May 2013 - 03:47 AM

hi,

is there a way to upload multiple files.

 

You can solve your problem by the following way. this is one kind of solution.

 

1) Controller use this:

 

           $crud->set_field_upload('upload_file_url','assets/uploads/photograph');
            $crud->set_field_upload('upload_file_url2','assets/uploads/biodata');

 

 

2) Create directory: 'biodata' and 'photograph' at 'assets/uploads' location

 

3) create two field in your table:

 

upload_file_url = varchar (255)

upload_file_url2=varchar(255)

 

4. Now run this.



#5 davidoster

davidoster

    Grocery CRUD Ninja

  • Advanced Member
  • PipPipPip
  • 1,068 posts
  • LocationAthens, Greece

Posted 14 May 2013 - 05:12 AM

likhon3k thanks for the post.

It is a solution but you can't really call it a solution for multiple upload can you?


____________________________________________________________

 

rtfm_small.jpg---!!!Please read these guidelines before asking to the forums!!!---

____________________________________________________________

 

David Oster aka George Pasparakis,
http://odphotography.com
http://eletter.gr


#6 victor

victor

    grocery CRUD Hero

  • Advanced Member
  • PipPipPip
  • 967 posts
  • LocationMinsk

Posted 16 May 2013 - 04:05 PM

ok. tomorrow I'll try to make this. I promised a long time ago. but I haven't much time for that, it'll be a short solution.

#7 bianconeri

bianconeri

    Member

  • Members
  • PipPip
  • 18 posts

Posted 17 May 2013 - 07:41 PM

Guys,
 
I want upload two images: normal and thumb.
 
My controller
 
$crud->set_table('table')
->columns('my_col')
->set_field_upload('file_url, 'exemple')
->callback_after_upload(array($this, 'upload'));
 
function upload($uploader_response, $field_info) {
$this->load->library('image_moo');
$file_uploaded = $field_info->upload_path . '/' . $uploader_response[0]->name;
$this->image_moo->load($file_uploaded)->resize(800, 600)->save($file_uploaded, true);
return true;
}
 
Now, how do I do to upload image thumb.
The field thumb can't show at form.


#8 bianconeri

bianconeri

    Member

  • Members
  • PipPip
  • 18 posts

Posted 20 May 2013 - 11:03 PM

I resolved my problem with 



$this->image_moo->load($file_uploaded)->resize(200, 200)->save($file_uploaded, true);
$this->image_moo->load($file_uploaded)->resize_crop(60, 40)->save_pa('', '_thumb');

But, when i remove my image,, the thumb continue at directory. How I delete the thumb?







Also tagged with one or more of these keywords: upload

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users