I'm testing a very simple form to upload a file. The model is shown
below along with the upload form control and trigger. When I use replace="all", I get the correct XML in the submitted instance like <form ui:upload-trigger=""> <file filename="organizations_simple2.xml" mediatype="text/xml" size="2166">file:/C:/DOCUME~1/wb177999/LOCALS~1/Temp/upload_00001889.tmp</file> </form> However, if I change to replace="instance", it does not seem to upload the file or fill-out the information and I get an instance like: <form ui:upload-trigger=""> <file filename="" mediatype="" size="">C:\Documents and Settings\wb177999\My Documents\My Documents\XML\DDI\Version3.0\Schemas\organizations_simple2.xml</file> </form> Is it no possible to use something else than replce="all" when using an upload control? thanks Pascal MODEL: <xforms:model> <!-- form instance --> <xforms:instance> <form ui:upload-trigger=""> <file filename="" mediatype="" size=""/> </form> </xforms:instance> <xforms:bind nodeset="file" type="xs:anyURI"/> <xforms:submission id="upload-submission" method="post" action="/ddi3/module-import-ddi3-action" replace="all"/> </xforms:model> FORM: <xforms:upload ref="file"> <xforms:filename ref="@filename" /> <xforms:mediatype ref="@mediatype" /> <xxforms:size ref="@size" /> </xforms:upload> <xforms:trigger ref="@ui:upload-trigger"> <xforms:label>Upload</xforms:label> <xforms:action ev:event="DOMActivate"> <xforms:send submission="upload-submission"/> </xforms:action> </xforms:trigger> -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws |
Administrator
|
Hi Pascal,
Your findings are accurate. At this point upload only works with replace="all". Alex On 3/15/06, Pascal Heus <[hidden email]> wrote: > I'm testing a very simple form to upload a file. The model is shown > below along with the upload form control and trigger. > > When I use replace="all", I get the correct XML in the submitted > instance like > <form ui:upload-trigger=""> > <file filename="organizations_simple2.xml" mediatype="text/xml" > size="2166">file:/C:/DOCUME~1/wb177999/LOCALS~1/Temp/upload_00001889.tmp</file> > </form> > > However, if I change to replace="instance", it does not seem to upload > the file or fill-out the information and I get an instance like: > <form ui:upload-trigger=""> > <file filename="" mediatype="" size="">C:\Documents and > Settings\wb177999\My Documents\My > Documents\XML\DDI\Version3.0\Schemas\organizations_simple2.xml</file> > </form> > > Is it no possible to use something else than replce="all" when using an > upload control? > > thanks > Pascal > > MODEL: > <xforms:model> > <!-- form instance --> > <xforms:instance> > <form ui:upload-trigger=""> > <file filename="" mediatype="" size=""/> > </form> > </xforms:instance> > <xforms:bind nodeset="file" type="xs:anyURI"/> > <xforms:submission id="upload-submission" method="post" > action="/ddi3/module-import-ddi3-action" replace="all"/> > </xforms:model> > > > FORM: > <xforms:upload ref="file"> > <xforms:filename ref="@filename" /> > <xforms:mediatype ref="@mediatype" /> > <xxforms:size ref="@size" /> > </xforms:upload> > > <xforms:trigger ref="@ui:upload-trigger"> > <xforms:label>Upload</xforms:label> > <xforms:action ev:event="DOMActivate"> > <xforms:send > submission="upload-submission"/> > </xforms:action> > </xforms:trigger> > > > > > -- > You receive this message as a subscriber of the [hidden email] mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > ObjectWeb mailing lists service home page: http://www.objectweb.org/wws > > > -- Blog (XML, Web apps, Open Source): http://www.orbeon.com/blog/ -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
--
Follow Orbeon on Twitter: @orbeon Follow me on Twitter: @avernet |
Free forum by Nabble | Edit this page |