You are here

function filefield_clear_session in FileField 5

Same name and namespace in other branches
  1. 5.2 filefield.module \filefield_clear_session()
1 call to filefield_clear_session()
filefield_widget in ./filefield.module
Implementation of hook_widget().

File

./filefield.module, line 226
Defines a file field type.

Code

function filefield_clear_session() {
  if (is_array($_SESSION['filefield']) && count($_SESSION['filefield'])) {
    foreach (array_keys($_SESSION['filefield']) as $fieldname) {
      filefield_clear_field_session($fieldname);
    }
    unset($_SESSION['filefield']);
  }
}