I work on D7, and create form from custom modules. Create a field upload images by $form['#attributes']['enctype'] = 'multipart/form-data'; $form['image'] = array(
'#type' => 'file',
'#title' => t('Upload picture'),
'#description' => t('Select a picture of at least @dimensionspx and maximum @filesize.', array(
'@dimensions' => '1000x1000',
'@filesize' => format_size(file_upload_max_size()),
)),
);
Show form correct.
and submit form by hook_form_submit(); print $form_state, upload images not find. How to get values of upload image.
Write Also
$file = file_save_upload('image', array( 'file_validate_is_image' => array(), 'file_validate_image_resolution' => array('500x500', '100x100'), ), 'public://uploaded_images/', FILE_EXISTS_RENAME);
Not find of upload image.