From cb860c2f75d23d54e13f0d3badec442c972e01b8 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Sun, 6 Apr 2008 04:08:03 +0000 Subject: [PATCH] Merged revisions 47612 via svnmerge from svn://svn.silverstripe.com/silverstripe/modules/sapphire/branches/2.2.0-mesq ........ r47612 | ischommer | 2008-01-04 19:11:57 +1300 (Fri, 04 Jan 2008) | 1 line formatting, removed saveInto() (same functionality as parent-class) ........ git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@52198 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- forms/FileIFrameField.php | 24 ++---------------------- 1 file changed, 2 insertions(+), 22 deletions(-) diff --git a/forms/FileIFrameField.php b/forms/FileIFrameField.php index cfce87c4f..0117593ff 100755 --- a/forms/FileIFrameField.php +++ b/forms/FileIFrameField.php @@ -1,12 +1,7 @@ name . 'ID'; - $hasOnes = $record->has_one($this->name); - if(!$hasOnes) $hasOnes = $record->has_one($fieldName); - - // assume that the file is connected via a has-one - if( !$hasOnes || !isset($_FILES[$this->name]) || !$_FILES[$this->name]['name']){ - return; - } - - $file = new File(); - $file->loadUploaded($_FILES[$this->name]); - - $record->$fieldName = $file->ID; - } + } ?> \ No newline at end of file