Hi,
I made this snippet to Ajax upload files in the Front End and "attach" then to documents (like a "gallery" for any file type) (Inspired by Pikachu’s FancyUpload snippet). At the moment it *does not* degrade well without Javascript, and is intended to be used *within* an FDM form (but could probably be used without).
There are some instruction in the FileAttach.txt file in the attached zip.
Features
--------
Templated output for both viewing files and editing files.
Can have any number of custom fields, with default content (e.g "description" field)
To be used *within* an FDM form when editing a document (but would probably work without FDM).
Ajax-ed uploads are only permanently saved when the containing FDM form is submitted (via standard non-Ajax post)
Status
------
*Very* early version
*Does not* degrade well (i.e. no Javascript, no upload)
*Does not* check for various failures of things when it probably should
Probably has some security holes (I really don’t know what I’m doing!)
Probably won’t work if things aren’t in default location
Probably dodgy in general
Any comments/suggestions? Useful? Any suggestions about features or coding very appreciated.
Michal.
huh is this real ? that’s a really useful snippet you did here ! I think a lot of people from the FDM thread didnt see this one !
i need something like that for a multi webuser private files repository with description and more... i will test it and i will report !
thanx by the way for sharing
CTRL+SHIFT+U - Clear Cache
CTRL+SHIFT+H - Hiding Heft Panel
CTRL+SHIFT+N - Fast Create Resource
CTRL+ALT+P - Preview Recource (in edit resorce window)
CTRL+ALT+S - Save