• Resolved Typing Services Divas

    (@typing-services-divas)


    Seems to be a conflict between this plugin and gravity forms.
    When I disable this plugin MP3 uploads fine.
    When I use the file validation tool below it reports it should be fine.
    I can upload Mp3 via the WP dashboard media file uploader.
    Ideas?

    VALIDATION:
    Naive Name: 8months-Int-ADP-AF01-2020-04-06-RC-v1.MP3
    Naive Extension: mp3
    Naive Type: audio/mpeg
    Magic Type: audio/mpeg
    Best Type: audio/mpeg

    FINAL:
    Name: 8month-Int-ADP-AF01-2020-04-06-RC.MP3
    Extension: mp3
    Type: audio/mpeg
    Code: 125

    SYSTEM:
    Kernel: Linux ip-172-26-4-190 4.4.0-1110-aws #121-Ubuntu SMP Fri Jun 12 04:21:59 UTC 2020 x86_64
    PHP: 7.3.14
    Modules: Core; PDO; Phar; Reflection; SPL; SimpleXML; Zend OPcache; bcmath; bz2; calendar; cgi-fcgi; ctype; curl; date; dom; exif; fileinfo; filter; ftp; gd; gettext; gmp; hash; iconv; imagick; imap; intl; json; ldap; libxml; mbstring; mysqli; mysqlnd; openssl; pcntl; pcre; pdo_mysql; pdo_sqlite; posix; readline; session; soap; sockets; sqlite3; standard; tidy; tokenizer; xml; xmlreader; xmlrpc; xmlwriter; xsl; zip; zlib
    WordPress: 5.4.2
    Plugins: blob-mimes [1.1.6]; gravityforms [2.4.19]
    Theme: transcriptdivas [2.0.2]

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Blobfolio

    (@blobfolio)

    Hi @typing-services-divas,

    I don’t have a Gravity Forms license so can’t run any actual tests, but I think your issue might simply be that your test file has capital letters in the name and extension (i.e. “.MP3” instead of “.mp3”).

    The plugin code I managed to dig up might be out of date, but it looks like the GFCommon::check_type_and_ext() wrapper calls WordPress’ wp_check_filetype_and_ext() method to validate file upload types, but mistakenly treats any renaming hints returned from that call as full-blown errors instead of, well, just taking the hint.

    
    if ( $proper_filename ) {
    	return new WP_Error( 'invalid_file', esc_html__( 'There was an problem while verifying your file.' ) );
    }
    

    As an easy follow-up step, try renaming that exact file on your computer to “test.mp3” (all lowercase, no weird characters, etc.), re-activate Lord of the Files, then retry your Gravity Form with “test.mp3” to see if it goes through.

    If it works with the simpler name, you should report the bug to Gravity Forms’ developers. Renaming hints should not be treated as errors; all that matters is that the renamed file still be of an allowed type. 🙂

    • This reply was modified 5 years, 9 months ago by Blobfolio.
    Thread Starter Typing Services Divas

    (@typing-services-divas)

    Fixed

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘MP3 being blocked’ is closed to new replies.