cancel
Showing results for 
Search instead for 
Did you mean: 

simple form with file upload

mrksjs
Champ on-the-rise
Champ on-the-rise
Hi,

if i want to provide a real simple page respectively form for entering some info/input fields plus upload of several files - whats the cheapest solution here?

that page should be accessible without needing a user/pass for alfresco.


customizing share is one possible solution but not an option for us (dont like hiding of functionality, not a clean solution, plus needs a user etc.)

simple webscript js/ftl with input forms and so on comes to my mind first. maybe even java backed webscript.

what else?



(sorry if alfresco apis is the wrong place to post this)
cheers
,
4 REPLIES 4

romschn
Star Collaborator
Star Collaborator
Do you want to do bulk upload of files in alfresco? Could you provide more details about what exactly you are trying to achieve? What is the overall requirement that you are trying to address? This will help us to give you right pointers.

mrksjs
Champ on-the-rise
Champ on-the-rise
Hi - no. no bulk import.

system should allow a (not logged in) user to create a 'file' in terms of: a report, a record …
the customer needs a system that allows anybody to fill out a html form and attach several documents to this 'file'.
alfresco then should create a folder and save the files and metadata which the user gave via form there.

another requirement would be input validation. email, country etc - can this be added to an upload-webscript in a simple manner as well?

cheers m

romschn
Star Collaborator
Star Collaborator
Take a look at this - http://wiki.alfresco.com/wiki/Web_Scripts_Examples#File_Upload which may be useful to you.

Hope this helps.

mrksjs
Champ on-the-rise
Champ on-the-rise
Hi Ramesh,

thank you very much. i have already adapted this upload webscript and it provided basically all i need - i wasnt sure if theres a more elegant or new way maybe in alfresco 4.2

additionally i need validation of fields in this webscript. do you know how this can be done?
i found this webscript which does very simple validation/mandatory check:
http://code.google.com/p/alfresco-bulk-filesystem-import/source/browse/src/main/resources/alfresco/e...

however, i would love to not to do this validation there manually. is it possible to do this validation based on the data model? by constraint for example.

i know there is Alfresco.forms.validation.email but i cant use it in the webscript since its not client side, right?