submit two file input fields in the same form

Here’s what I think is happening. I’ve added comments to the relevant sections of your code. // You use the $_FILES superglobal to get the uploaded files. if (isset($_FILES[‘file_metabox’])) { $file_metabox = $_FILES[‘file_metabox’]; foreach ($file_metabox[‘name’] as $key => $value) { if ($file_metabox[‘name’][$key]) { // … // Here you **overwrite** the $_FILES superglobal. $_FILES = array(“file_metabox” … Read more

Saving a Custom Post Type with a Meta Box results in a “Updating Failed” error

I changed your code and its now working fine in my pc. here is the code <?php function declare_custom_post_type() { $theme_name=”thatannalam”; $custom_post_type=”favourites”; $labels = array( ‘name’ => __(‘Favourites’, $theme_name), ‘singular_name’ => __(‘Favourite’, $theme_name), ‘add_new’ => __( ‘Add New Favourite’ ), ‘add_new_item’ => __( ‘Add New Favourite’ ), ‘edit_item’ => __( ‘Edit Favourite’ ), ‘new_item’ => … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)