SproutCMS

This is the code documentation for the SproutCMS project

function chunkedUpload()

Generates a file upload field with a progress bar

To easily save the uploaded files in the form action function, see File::replaceSet

Usage

unknown Fb::chunkedUpload ( string $name , array $attrs , array $params );

Arguments

  1. string $name
  2. array $attrs
  3. array $params
    Must have 'sess_key' => session key, e.g. 'user-register'.
           Data regarding each uploaded file will typically be saved in
           $_SESSION['file_uploads'][$params['sess_key']][$name].
    
           May also have 'opts' which can contain any of the following:
           - 'begin_url' (string)
           - 'form_url' (string)
           - 'done_url' (string)
           - 'cancel_url' (string)
           - 'form_params' (array):
               - form_id (string)
               - field_name (string)
    
           May also specify 'multiple', which is a positive int (default: 1).
           If more than 1, multiple files are allowed, up to the number specified.