How can I modify the media upload form fields?

Would maybe look into do_action( ‘pre-upload-ui’ );. Here is my first thoughts, please note it’s not tested but should get you in the right direction. add_action( ‘pre-plupload-upload-ui’, ‘sd_extra_info’ ); function sd_extra_info() { # see wp-includes/media-template.php print ‘<pre> Some more info here </pre>’; }

Stop image resizing in particular case – is that possible?

Use the Filter Hook intermediate_image_sizes_advanced for control the resize function for different sizes. This hook get a array of different sizes and can control your resize with your requirements. Add your logic inside a plugin and remove sizes via this hook. // the hook in core $sizes = apply_filters( ‘intermediate_image_sizes_advanced’, $sizes ); A small example … Read more

When does WP resize an image file

WordPress resizes the image when you upload it. By default it provides 4 sizes of your image (providing your image is bigger than the ‘large’ size). the_post_thumbnail(‘thumbnail’); // Thumbnail (default 150px x 150px max) the_post_thumbnail(‘medium’); // Medium resolution (default 300px x 300px max) the_post_thumbnail(‘large’); // Large resolution (default 640px x 640px max) the_post_thumbnail(‘full’); // Original … Read more

“page not found” due to hat character (“^”) in a upload file name

This is a filter I use to keep my clients from adding special characters to their filenames, should work for you – you’ll have to reupload the file though. /** /* Sanitize Uploaded Filenames /* @param array $file /* @return array $file */ function sanitize_file_uploads( $file ){ $file[‘name’] = sanitize_file_name($file[‘name’]); $file[‘name’] = preg_replace(“/[^a-zA-Z0-9\_\-\.]/”, “”, $file[‘name’]); … Read more