On Jan 16, 2008 9:16 AM, Tobias Bocanegra <[EMAIL PROTECTED]> wrote: > ...i suggest to implement a default behaviour that creates an 'nt:file' > subnode for that uploaded file if the field name has a trailing slash > (and if the request parameter is a file upload), eg: >
Why not make this the default behaviour, without using the "magic trailing slash": <form action="/home/tripod/profile" method="post" enctype="multipart/form-data"> <input type="file" name="./portrait/" /> </form> Would create an nt:file structure as you suggest. And we could use the @TypeHint if we want to store the file data in a binary property, i .e: <form action="/home/tripod/profile" method="post" enctype="multipart/form-data"> <input type="file" name="./portrait" /> <input type="hidden" name="./portrait/@TypeHint" value="jcr:Property"/> </form> WDYT? -Bertrand
