
Join free
Skip to: site menu |main content
Welcome to my personal site. If You have any question or suggestion please feel free to contact me from contact page.
In drupal 6 you can use file_save_upload() function for saving your uploaded files.Instead of mannually accessing $_FILES drupal standard is prefered.
<?php
file_save_upload($source, $validators = array(), $dest = FALSE, $replace = FILE_EXISTS_RENAME);
?>For making your custom form to work for file upload you need to set Enctype for your form in following manner:-
<?php
$form['#attributes'] = array('enctype' => "multipart/form-data");
?>InderSingh.com v1.2
(May 22, 2012)
Recent comments
17 weeks 1 day ago
17 weeks 1 day ago
17 weeks 1 day ago
1 year 16 weeks ago
1 year 16 weeks ago
1 year 16 weeks ago
1 year 32 weeks ago
1 year 33 weeks ago
1 year 35 weeks ago
1 year 39 weeks ago