Re: libXML loading one xml on top of another (?)
Tod Harter <[email protected]>
| Newsgroups | gmane.comp.lang.perl.xml |
|---|---|
| Message-ID | <[email protected]> |
There are various possibilities. You could merge the empty data first, then the 'real' data. You can certainly apply multiple XSLT transforms to the same DOM. However it sounds more like you'll maybe want to take a look at the XSLT document() function, which lets you access external data during a transform. So you can then have the XSLT, the XML to be transformed, and any number of other data files loaded via document() which you can apply template matching rules on. On Tue, Mar 17, 2009 at 2:16 PM, Howard, Chris <[email protected]> wrote: > > You guys were very helpful with my recent query. I am still > going in the direction of using XForms to do my browser form > that I asked about. > > I have another question: In the tutorial information about XForms > that I have, they are able to have repeating groups of form fields > on the screen and then (while still in the browser, before hitting > "submit") they can add and remove lines from the repeating groups. > > As you can imagine, that would work well for line items of an invoice > type of form. The user could add or remove new line items. > > The problem is that I have some optional repeating groups. So > an xml file to be edited my not have any of those particular elements > when it comes to be edited. Since XForms is based on the incoming > xml, I don't see any way for a user to add those non-existant > elements. > > What I'm thinking is maybe I can build an "empty" xml file which > has just repeating groups with no data or dummy data, then overload > my data to be edited. After editing I would then strip out the > dummy data. > > I'm using libXML, is it possible to load two xml files into > one parser? First would be the empty data file, then the > true data. Is that sensible? I don't want it to extend the > empty data with true data but to replace. > > Chris > > > _______________________________________________ > Perl-XML mailing list > [email protected] > To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs > -- The Wise adapts himself to the world. The Fool adapts the world to himself. Therefore, all progress depends on the Fool. _______________________________________________ Perl-XML mailing list [email protected] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs