WordPress.org

Support

Support » Plugins and Hacks » Use the max size filter

Use the max size filter

  • Hi, I am trying to limit the max file size to the image.

    This is what I am doing in my theme functions.php

    function pdo_avatar_limit($size) {
    $size = 102400;
    return $size;
    }
    add_filter(‘simple_local_avatars_upload_limit’, ‘pdo_avatar_limit’);

    I dont know what is the problem, but it seems that the filter is never called because I still can upload big images (even if I do $size = 10;)

    http://wordpress.org/plugins/simple-local-avatars/

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Use the max size filter’ is closed to new replies.