W3C home > Mailing lists > Public > www-forms@w3.org > October 2005

What is the best way to deep copy an element?

From: Flinton Adam <Adam.Flinton@cfh.nhs.uk>
Date: Mon, 17 Oct 2005 18:28:46 +0100
Message-ID: <595299DD7F30014BBCE48B93DCB60652031DB5CE@EXCHAQ2.nhsia.nhs.uk>
To: <www-forms@w3.org>

Dear All,

I am trying to write an Xforms app which allows a user to add & change
annotations written in XHTML where the annotation is contained within a

If I use a repeat e.g.:

<xf:repeat id="r2" style="" nodeset="mif:class/mif:attribute">
<xf:output ref="@name">
style="width: 50%; text-align: left; vertical-align: top;">
<xf:textarea id="annotation" ref="mif:annotation/*" />

Then I just get the first bit of text etc but the moment it rus into an
xhtml element (e.g. <p> </p> then that's the end.

I noticed that itemset contains a copy element:


9.3.4 The copy Element

Which seems to do what I require (i.e. copy everything between
<annotation & </annotation>

There is (at present) only one annotation & I am wondering if within the
repeat I can "auto-select" the single choice

Just out of interest, why isn't there a copy element in a repeat? I you
are looking to display/edit chunks of XHTML (e.g. as documentation) then
it may be necessary.



This e-mail is confidential and privileged. If you are not the intended recipient please accept our apologies; please do not disclose, copy or distribute information in this e-mail or take any action in reliance on its contents: to do so is strictly prohibited and may be unlawful. Please inform us that this message has gone astray before deleting it. Thank you for your co-operation.
Received on Monday, 17 October 2005 17:27:13 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:36:16 UTC