W3C home > Mailing lists > Public > www-forms@w3.org > September 2003

RE: external model

From: Micah Dubinko <MDubinko@cardiff.com>
Date: Mon, 15 Sep 2003 18:21:29 -0700
Message-ID: <BD2DBD26EE0BAA48B1A425C7BE7923002D06C7@csmail.cardiff.com>
To: 'Matthias Kind' <mkind@dstc.edu.au>, "'Chalker, Dean'" <Dean.Chalker@intelliwhere.com>
Cc: www-forms@w3.org

Would XML Include meet your needs for an external model? Why or why not?

http://www.w3.org/TR/xinclude/

.micah

-----Original Message-----
From: Matthias Kind [mailto:mkind@dstc.edu.au]
Sent: Monday, September 08, 2003 7:45 PM
To: 'Chalker, Dean'
Cc: www-forms@w3.org
Subject: RE: external model



Hi Dean and Others,

the feature that you can refer to an external instance data is quite
helpful. But I was actually looking for something where the *entire* model
can be defined in an external file, which than can be used together with
different user interface implementations. 

Such as depicted on the XForms homepage http://www.w3.org/MarkUp/Forms/
under section "What are XForms?". You define your model just once and than
you can plug it into different presentation documents, such as XHTML, WML,
SVG, etc. 

Ok, from a logical point of view it works this way right now. But when it
comes down to implement a model into XHTML, the model definition must be
'hard coded' into that document. If you wanna use the same model with SVG,
it has to be 'hard coded' into that document as well. If there's a change in
the model, you would have to change it in 2 documents. :-(

So is there any way to refer to an entire model (not just the instance data)
that is outside the actual presentation document?

cheers,
Matthias


-----Original Message-----
From: Chalker, Dean [mailto:Dean.Chalker@intelliwhere.com] 
Sent: Tuesday, 9 September 2003 9:23 AM
To: 'Matthias Kind'


Hi Matthias,

I'm an xforms newbie, but I thought I'd make a response anyway.  Perhaps it
will trigger some discussion from the gurus :-)

I don't know about a external mode, but you can get external instances with
the instance src attribute.  This may be what you want, since it leaves the
submission and bind elements with the form description, which is probably
where you want them.

    <xforms:model>
        <xforms:instance src="some-URI"/>
        ...
    </xforms:model>


However, there seems to be no way to point to an external fragment, rather
than an entire document.  The application that I am thinking about would
benefit from a single XML instance document with a "library" of XForm forms
for viewing/editing fragments from the common document.  Perhaps something
like:

    <xforms:model>
        <xforms:instance src="some-URI"
ref="xpath-description-of-instance-fragment"/>
        ...
    </xforms:model>

Dean



>  -----Original Message-----
>  From: Matthias Kind [mailto:mkind@dstc.edu.au]
>  Sent: Monday, 8 September 2003 2:54 PM
>  To: www-forms@w3.org
>  Subject: external model
>  
>  
>  
>  Hi there,
>  
>  is there a way, to specify a complete xforms model in an  external 
> file and  just refering to it? So that, for example, a hosting XHTML  
> document only  would need to implement the XForms UI components and 
> just  contain a link to  the model?
>  
>  I was thinking of something like that: (as linking to an external
>  stylesheet)
>  
>  ...
>  <head>
>    ...
>    <link id="myModel" href="myModel.xml" type="text/xml" 
>  rel="subsection" />
>    ...
>  </head>
>  <body>
>    ...
>    <xform:input model="myModel" ref="/data/test">
>      <xforms:label>Enter test data<xforms:label>
>    </xforms:input>
>    ...
>  </body>
>  ...
>  
>  Any ideas?
>  
>  cheers,
>  Matthias
>  
Received on Monday, 15 September 2003 21:21:33 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 10 March 2012 06:21:56 GMT