Skip to:
Content
Pages
Categories
Search
Top
Bottom

Allow all characters in a PHP “explode” function


  • Uncle Nerdicus
    Participant

    @nerdicus99

    I have a piece of PHP code that gets a list of allowed extensions from the WordPress Database and only allows files uploaded that are those file extensions. What I would like to do is make the code allow ALL extensions but NOT allow only a couple of file extensions (executables like exe, shells, binaries, etc.)

    Here is the code:
    $allwd_ext = get_option( ‘ma_allowedExtension’ );
    $allowedExts = explode(“,”,$allwd_ext);
    $extension = end(explode(“.”, $_FILES[$f_u][“name”]))`;

    Any ideas appritiated 🙂

Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Allow all characters in a PHP “explode” function’ is closed to new replies.
Skip to toolbar