Upload media file problem

I’d suggest asking your client what value is shown when adding media, as shown here in the screenshot.

enter image description here

If the value shown is 1mb then i can tell you the function responsible is the following.

function wp_max_upload_size() {
    $u_bytes = wp_convert_hr_to_bytes( ini_get( 'upload_max_filesize' ) );
    $p_bytes = wp_convert_hr_to_bytes( ini_get( 'post_max_size' ) );
    $bytes = apply_filters( 'upload_size_limit', min($u_bytes, $p_bytes), $u_bytes, $p_bytes );
    return $bytes;
}

Found in wp-admin/includes/template.php
http://core.trac.wordpress.org/browser/tags/3.0.4/wp-admin/includes/template.php#L2712

As you can see from the above function, the value is first determined by the server ini configuration and secondly by any filters hooked onto upload_size_limit. If the server configuration is not matching what you see displayed, then my guess would be a plugin/theme adding a filter onto upload_size_limit which is imposing a different file size limit.

Additional
Some support topics that mention a similar problem.
http://wordpress.org/support/topic/upload-limit-problems-on-local-site
http://wordpress.org/support/topic/multiple-domain-mod-limits-file-uploads-to-1mb
http://wordpress.org/support/topic/max-upload-size-problem-yes-again

Leave a Comment