CodeIgniter Forums
[SOLVED] uploading image in CI? - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forum-21.html)
+--- Thread: [SOLVED] uploading image in CI? (/thread-26491.html)



[SOLVED] uploading image in CI? - El Forum - 01-14-2010

[eluser]maria clara[/eluser]
hi,

i have a script for uploading an image, it works well but it doesn't store the image in the database. and it even don't send the image to the destination i put in the CI.
Code:
$config['upload_path'] = './reports/module/';
                $config['allowed_types'] = 'gif|jpg|png';
                $config['max_size']    = '100';
                $config['max_width']  = '1024';
                $config['max_height']  = '768';
                $this->load->library('upload', $config);
                $file_data = $this->upload->data();
                $file_name = $file_data['file_name'];
                
                    $fields = array(
                            "module_name",
                "slug",
                "report_file_name",
                "icon"=>$file_data['file_name'],
                            "sql_select",
                            "sql_filter",
                            "sql_order"
                            );


help anyone??

thanks,
maria


[SOLVED] uploading image in CI? - El Forum - 01-15-2010

[eluser]richthegeek[/eluser]
User guide. It's a useful guide for users.

http://ellislab.com/codeigniter/user-guide/libraries/file_uploading.html

Specifically the Controller section and how it deals with errors.


[SOLVED] uploading image in CI? - El Forum - 01-15-2010

[eluser]maria clara[/eluser]
[quote author="richthegeek" date="1263559965"]User guide. It's a useful guide for users.

http://ellislab.com/codeigniter/user-guide/libraries/file_uploading.html

Specifically the Controller section and how it deals with errors.[/quote]

thanks,im reading it right now.