On Tue, Feb 23, 2010 at 16:43, Simon Gaeremynck <[email protected]> wrote: > I'm trying to upload a file and set properties on them at the same time. > ... > I can now do something like: > curl -F"./*[email protected]" -F"./*...@typehint=sakai:file" > http://admin:ad...@localhost:8080/foo/bar > curl -F"stringProp=alfa" http://admin:ad...@localhost:8080/foo/bar/README.txt
Try specifying the * (for auto-node name generation) as part of the POST URL. Using :nameHint you can control the node name generation further [1]. Using the file name of the uploaded file is not supported this way AFAIK, but it's generally not such a good idea anyway. curl -u admin:admin [email protected] -...@typehint=sakai:file -F./stringProp=alpha http://localhost:8080/foo/bar/* [1] http://sling.apache.org/site/manipulating-content-the-slingpostservlet-servletspost.html#ManipulatingContent-TheSlingPostServlet%28servlets.post%29-AlgorithmforNodeNameCreation Regards, Alex -- Alexander Klimetschek [email protected]
