Also, in your model's form_fields method, I would use the "file" field type. In the example, below it is uploading into folder assets/images/galleries/{name} folder where {name} would be the gallery's name field in the model: ...
form_fields($values = array(), $related = array())
{
$fields = parent::form_fields($values, $related);
$fields['image'] = array('type' => 'file', 'folder' => 'images/galleries/{name}');
return $fields;
} http://docs.getfuelcms.com/general/forms#file
Comments
http://docs.getfuelcms.com/general/models#relationships
Also, in your model's form_fields method, I would use the "file" field type. In the example, below it is uploading into folder assets/images/galleries/{name} folder where {name} would be the gallery's name field in the model:
... form_fields($values = array(), $related = array()) { $fields = parent::form_fields($values, $related); $fields['image'] = array('type' => 'file', 'folder' => 'images/galleries/{name}'); return $fields; }
http://docs.getfuelcms.com/general/forms#file