[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Challenge


RE:  Challenge
Hi Klotz,

Klotz said:
  Why use //description, etc rather than /demo/description?

Actually, since XForms sets the XPath context node to be the document
element, you can jus tsay
       <xforms:bind id="version" nodeset="version" constraint=". = '1.0'"/>
       <xforms:bind id="name" nodeset="author/name"/>
       <xforms:bind id="email" nodeset="author/email"/>
       <xforms:bind id="description" nodeset="description"/>

  <!-- snip -->

Didier replies:
Yes you are right about /demo/description.

Klotz said:
Actually it would be
    <xforms:input
ref="version"><xforms:label>Version</xforms:label></xforms:input>

Didier replies:
Only if you want to use xforms widgets. If you implement the XForms engine
with XSLT which is, by the way, a kind of interpreter, and if you want to
use XHTML widgets, then you use 
<xforms:submission id="submit" 
                            xforms:replace="all"
                            xforms:action="http://mydomain.com/MyStorage"
                            xforms:method="PUT"/>
     <xforms:instance src=http://myDomain.com/theChallenge.xml" />
                            .....
                            .....
     <!-- an XHTML widget -->
     <input ref="demo/version" type="text" name="version" size="20"/> 

Klotz said:
Note that the context node being "/data" means that you can just use the ref
to ne the immediate child name of the toplevel element,
so it looks a lot like what XHTML 1 does with <input name="version"/>.  In
fact, if you omit the <instance> from a model entirely,
XForms will notice that and make one up for you populated by elements with
names taken from the form controls bound to the model.
It's a good transition step from XHTML 1 to XHTML 2 or other XForms host
languages.

Didier replies:
I wasn't able to find what the spec says about that. Do you know where that
process is specified?

Cheers
Didier PH Martin
http://didier-martin.com



  All the best

  Mark  

  > Cheers
  > Didier PH Martin
  > http://didier-martin.com
  > 
  > 
  > 
  > 
  > -----------------------------------------------------------------
  > The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
  > initiative of OASIS <http://www.oasis-open.org>
  > 
  > The list archives are at http://lists.xml.org/archives/xml-dev/
  > 
  > To subscribe or unsubscribe from this list use the subscription
  > manager: <http://lists.xml.org/ob/adm.pl>
  > 


  -----------------------------------------------------------------
  The xml-dev list is sponsored by XML.org <http://www.xml.org>, an
  initiative of OASIS <http://www.oasis-open.org>

  The list archives are at http://lists.xml.org/archives/xml-dev/

  To subscribe or unsubscribe from this list use the subscription
  manager: <http://lists.xml.org/ob/adm.pl>



  • References:

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.