OK, maybe I need to describe my use case.
It's an application form.
I've created a form that asks anonymous users to submit name, country,
sex, etc. and picture, CV (in pdf format) and a few other data. (Of
course, I have a captcha field...)
The form works fine with Mail and SaveData Adapter. But I have been
asked to store the PDF's in the plone site for the people who actually
will get access to the data.
It's probably best to collect the files in a folder per applicant.
Anyway, I was already so far to go into the direction that Andreas
suggested, i.e. adding a script adapter, but now I am pretty helpless
since I've not done such things before.
As I said, I'd appreciate code that approximately deals with such an
issue. I cannot be the first who ran into such a use case.
If there is no code, more specific pointers into the documentation would
be highly appreciated. I simply don't know what how to read the file
field and turn it into a file in plone. Some code snippets available to
get me started?
Thank you in advance.
Ralf
On 11/02/2009 03:48 PM, David Hostetler wrote:
> Is there a particular reason you feel the need to use PFG? (don't get
> me wrong, I <3 PFG)
>
> Correctly handling the upload and storage of PDFs (or any other file) as
> a plone content object is precisely what ATFile is for. Have you
> thought about just having a custom page that offers up the equivalent of
> the 'add new' -> 'File' action? I.e. using the mechanism behind the
> following:
>
> http://<your plone site>/createObject?type_name=File
>
> If you stick with PFG, what you'll likely end up doing is using the same
> mechanism anyway, within a custom external method hooked in as either
> the success action or the validation.
>
> regards,
>
> -hoss
>
>
> On Mon, Nov 2, 2009 at 07:47, Ralf Hemmecke <
[hidden email]
> <mailto:
[hidden email]>> wrote:
>
> Hello,
>
> I would like to use PloneFormGen to upload PDFs into a special folder of
> my site. According to
>
>
http://plone.org/plone.org/products/ploneformgen/issues/5>
> and PFGs current behaviour, the files are not saved with the
> SaveDataAdapter. (The MailAdapter is not an option for me, I want the
> files automatically in my Plone Site.)
>
> I'll probably have to program something, but I'm almost sure someone has
> already done a similar job. Could this person share the code or give
> some concrete hints how this can be done or how to narrow my plone
> documentation search space.
>
> Thank you in advance.
>
> Ralf
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference_______________________________________________
Plone-Users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/plone-users