How to Populate xml element attributes with Orbeon XForms

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

How to Populate xml element attributes with Orbeon XForms

Randy Smith-9
Hope this is not a dumb question:
Can you and/or how do you populate xml element attributes with Orbeon XForms?
Usually you have an input like:
<xforms:input ref="DocID">
      <xforms:label class="doc-label">
Doc1</xforms:label>
</xforms:input>

that asks for the element content to be filled in to end up with<DocID>Doc1</DocID>.
How would you fill in a necessary attribute to end up with:
<DocID type="internal">Doc1</DocID>
?

Thanks
Randy


--
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
Reply | Threaded
Open this post in threaded view
|

RE: How to Populate xml element attributes with Orbeon XForms

Steve Bayliss
Message
ref is xpath, so theoretically ref="DocID/@type"
-----Original Message-----
From: Randy Smith [mailto:[hidden email]]
Sent: 11 August 2009 17:00
To: [hidden email]
Subject: [ops-users] How to Populate xml element attributes with Orbeon XForms

Hope this is not a dumb question:
Can you and/or how do you populate xml element attributes with Orbeon XForms?
Usually you have an input like:
<xforms:input ref="DocID">
      <xforms:label class="doc-label">
Doc1</xforms:label>
</xforms:input>

that asks for the element content to be filled in to end up with<DocID>Doc1</DocID>.
How would you fill in a necessary attribute to end up with:
<DocID type="internal">Doc1</DocID>
?

Thanks
Randy


--
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
Reply | Threaded
Open this post in threaded view
|

Re: How to Populate xml element attributes with Orbeon XForms

Ger G
In reply to this post by Randy Smith-9
Hi Randy,
To reference an attribute in XPath, you use "@".
For your example it would be "DocID/@type".

Regards,
German


On Tue, Aug 11, 2009 at 1:00 PM, Randy Smith <[hidden email]> wrote:
Hope this is not a dumb question:
Can you and/or how do you populate xml element attributes with Orbeon XForms?
Usually you have an input like:
<xforms:input ref="DocID">
      <xforms:label class="doc-label">
Doc1</xforms:label>
</xforms:input>

that asks for the element content to be filled in to end up with<DocID>Doc1</DocID>.
How would you fill in a necessary attribute to end up with:
<DocID type="internal">Doc1</DocID>
?

Thanks
Randy


--
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




--
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
Reply | Threaded
Open this post in threaded view
|

Re: Re: How to Populate xml element attributes with Orbeon XForms

Randy Smith-9
Thanks SO much!!

Ger G wrote:
Hi Randy,
To reference an attribute in XPath, you use "@".
For your example it would be "DocID/@type".

Regards,
German


On Tue, Aug 11, 2009 at 1:00 PM, Randy Smith <[hidden email]> wrote:
Hope this is not a dumb question:
Can you and/or how do you populate xml element attributes with Orbeon XForms?
Usually you have an input like:
<xforms:input ref="DocID">
      <xforms:label class="doc-label">
Doc1</xforms:label>
</xforms:input>

that asks for the element content to be filled in to end up with<DocID>Doc1</DocID>.
How would you fill in a necessary attribute to end up with:
<DocID type="internal">Doc1</DocID>
?

Thanks
Randy


--
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




--
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
Reply | Threaded
Open this post in threaded view
|

Re: RE: How to Populate xml element attributes with Orbeon XForms

Randy Smith-9
In reply to this post by Steve Bayliss
Thanks Steve!!

Steve Bayliss wrote:
Message
ref is xpath, so theoretically ref="DocID/@type"
-----Original Message-----
From: Randy Smith [[hidden email]]
Sent: 11 August 2009 17:00
To: [hidden email]
Subject: [ops-users] How to Populate xml element attributes with Orbeon XForms

Hope this is not a dumb question:
Can you and/or how do you populate xml element attributes with Orbeon XForms?
Usually you have an input like:
<xforms:input ref="DocID">
      <xforms:label class="doc-label">
Doc1</xforms:label>
</xforms:input>

that asks for the element content to be filled in to end up with<DocID>Doc1</DocID>.
How would you fill in a necessary attribute to end up with:
<DocID type="internal">Doc1</DocID>
?

Thanks
Randy


--
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