|
Thursday 21 April 2005 6:18:54 am
Comment42937
I think the best and easiest way of getting multiple files in one object without having more than one ezbinaryfile in class is with ezobjectrelationlist.
To setup this just do the following:
1. Add a new attribute of datatype ezobjectrelationlist in the class where you want to have multiple file-uploads
2. Set up this new attribute as you need it. E.g. say only objects of class "binaryfile" can be related and shouldn't be stored in the content-tree.
3. Create a new object of your class. You now can create other objects within this object of the class binaryfile. 4. Create new templates and overrides for your class. Standard Exponential doesn't come with working ones for embeded views with ezobjectrelationlist.
Tips and tricks:
-You can create a new class replacing the class binaryfile if the standard-class binaryfile does not fit your needs (e.g. you think there are to many fields within that class) -Just copy the full view of ezbinaryfile to the embed view in our design-override and set up your override.ini. Compare it with the overrides for the article, wich has some embed-entries. How nice this works (even for other needs than fileupload - e.g. images, texts, links, ...) you can see on your website on this page: http://web.ymc.ch/kunden/success_stories/soreon_research
We use for this page a class which looks like this:
-Name (ezstring)
-Shortname (ezstring) -Attributes (ezobjectrelationlist)
For the attributes we can use the following classes:
-Image (form standard-setup)
-Link (form standard-setup)
-File (from standar-setup)
-Flash (form standard-setup)
-Quicktime (form standard-setup)
-Windows Media (form standard-setup)
-Real Video (form standard-setup)
-Textline (new class with just one attribute of datatype ezstring)
-Textarea (new class with just one attribute of datatype eztext)
-XMLtextarea (new class with just one attribute of datatype ezsxmltext) -Paragraph (new class which just adds a paragraph of specific height)
Daniel Beyer
_________________________________
YMC AG
Kreuzlingen, Switzerland
web: www.ymc.ch
____________________________________
|