3093 Posts in 875 Topics by 654 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 791 Views |
-
Uploading a Flash file (.swf) to a page

17 January 2011 at 6:32am
I created a new page type by extending Page. A requirement for the new page type is content editors to be able to add a Flash file (.swf).
I added the following code to the page type (ProjectPage), but now struggling with modifying getCMSFields() to add the field to a tab:
static $has_one = array(
'Photo' => 'Image',
'FlashHeader' => 'File'
);Which FormField to use for uploaded files (not images) in addFieldToTab method?
-
Re: Uploading a Flash file (.swf) to a page

17 January 2011 at 7:36am Last edited: 25 February 2011 11:00am
FileUploadFieldFileIframeField is probably your best bet. -
Re: Uploading a Flash file (.swf) to a page

17 January 2011 at 8:00am
Where can I find information about FileUploadField?
The following results in an error ("Fatal error: Class 'FileUploadField' not found in ..."):
function getCMSFields() {
...
$fields->addFieldToTab("Root.Content.Main", new FileUploadField('FlashHeader'));
...
}
| 791 Views | ||
|
Page:
1
|
Go to Top |


