unable to execute a exist query in xform <xforms:model> <!--<xforms:instance src="oxf:/apps/program-demo/programs.xml" id="programs-instance">--> <!--<xforms:instance src="http://localhost:9080/exist/rest/db/program.xml" id="programs-instance">--> <xforms:instance id="programs-instance"> <programs> <exist:query> <exist:text> declare namespace request="http://exist-db.org/xquery/request"; let $id := request:request-parameter("id","") let $program := doc("db/program.xml")/programs/program[id=2] return $program </exist:text> </exist:query> </programs> </xforms:instance> <xforms:bind nodeset="program"> <xforms:bind nodeset="programname" /> <xforms:bind nodeset="programdescription" /> <xforms:bind nodeset="datasourcetype" /> </xforms:bind> </xforms:model> <body> <xforms:variable name="qrystring" select="2" /> <h1> Edit <xforms:output ref="instance('programs-instance')//program/programname"/></h1> <a href="http://localhost:8080/orbeon/program-demo/">Home</a> <xforms:group ref="instance('programs-instance')/program"> <xforms:input ref="programname"> <xforms:label>ProgramName</xforms:label> </xforms:input><br/> <xforms:textarea ref="programdescription" appearance="xxforms:autosize"> <xforms:label>Program Description</xforms:label> </xforms:textarea> <br/> <xforms:select1 ref="datasourcetype"> <xforms:label>DataSourceType</xforms:label> <xforms:item> <xforms:label>Choose one...</xforms:label> <xforms:value/> </xforms:item> <xforms:itemset nodeset="instance('datasources-instance')/datasourcetype"> <xforms:label ref="name"/> <xforms:value ref="value"/> </xforms:itemset> </xforms:select1> <br/> <xforms:submit submission="p1"><xforms:label>Submit</xforms:label></xforms:submit> </xforms:group> -- 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 OW2 mailing lists service home page: http://www.ow2.org/wws |
Free forum by Nabble | Edit this page |