Welcome Guest, Not a member yet? Register   Sign In
image upload
#2

[eluser]BrianDHall[/eluser]
Here you go, from the manual on file uploading:
Quote:$this->upload->do_upload()

Performs the upload based on the preferences you've set. Note: By default the upload routine expects the file to come from a form field called userfile, and the form must be a "multipart type:

<form method="post" action="some_action" enctype="multipart/form-data" />
If you would like to set your own field name simply pass its value to the do_upload function:

$field_name = "some_field_name";
$this->upload->do_upload($field_name)

In your do_upload call you aren't passing a field name, but your file upload field is not called 'userfile' - so CI is looking for a posted file field that just doesn't exist.

I think thats the only problem, I can't see anything else wrong.


Messages In This Thread
image upload - by El Forum - 09-16-2009, 05:39 AM
image upload - by El Forum - 09-16-2009, 08:31 AM
image upload - by El Forum - 09-16-2009, 09:42 PM
image upload - by El Forum - 09-17-2009, 04:37 PM



Theme © iAndrew 2016 - Forum software by © MyBB