public function proccessField(Form $form) { if ($this->isClicked()) { $this->onClick(); } parent::proccessField($form); }
public function proccessField(\Meta\Form $form) { // move the uploaded file to the files directory if ($this->uploadedFile()) { if (!$this->hasErrors()) { $tmpName = $_FILES[$this->altName()]['tmp_name']; $file = \Meta\FileSystem::getFilesPath() . '/' . $this->getValue(); move_uploaded_file($tmpName, $file); } } parent::proccessField($form); }