[opencms-dev] How to let a user upload in VFS
Thomas Maerz
thomasmaerz at gmx.de
Mon Aug 1 15:11:39 CEST 2005
Alessandro Magnolo <alessandro.magnolo at gmail.com> writes:
> - first of all you need to get the CmsRequestHttpServlet
> - from CmsRequestHttpServlet you get the uploaded files
Replace the two points above with commons fileUpload:
http://jakarta.apache.org/commons/fileupload/using.html
Actually this is quite easy, just follow the examples.
The jar is already in your WEB-INF/lib/ folder.
> - switch to offline project
> - save the file in VFS
> - publish the file
> - switch back to online
>
> Unfortunately, this solution doesn't work in OpenCms 6, since
> CmsRequestHttpServlet is deprecated. An alternative is needed.
The rest (3-6) stays the same. For more information search the mailing
list for CmsRequestContext, cmsObject.login ...
Regards,
Thomas
More information about the opencms-dev
mailing list