Your location:Tech News>News>Script>_php example ThinkPHP achieve attachment upload script _ Home

Latest News

_php example ThinkPHP achieve attachment upload script _ Home

Author:fsadmin

Views:

  private $ config = array (

  ''Mimes'' => array (), // allow upload file type MiMe

  ''MaxSize'' => 0, // upload file size limit (0 - no limit)

  ''Exts'' => array (), // allow upload file extension

  ''AutoSub'' => true, // automatically save files subdirectory

  ''SubName'' => array ( ''date'', ''Ym-d''), // create a subdirectory embodiment, [0] - function name, [1] - parameters, a plurality of parameters using arrays

  ''RootPath'' => ''https: // www.jb51.net / article / Uploads / '', // save root path

  ''SavePath'' => '''', // save path

  ''SaveName'' => array ( ''uniqid'', ''''), // upload files naming convention, [0] - function name, [1] - parameters, a plurality of parameters using arrays

  ''SaveExt'' => '''', // save the file suffix, using the original empty suffix

  ''Replace'' => false, // if name exists cover

  ''Hash'' => true, // whether the generated hash coding

  ''Callback'' => false, // file exists callback detection, if there is an array of file information is returned

  ''Driver'' => '''', // file upload driver

  ''DriverConfig'' => array (), // drive configuration upload

  );

Recommend article

Relate article