Re: XML_Functions
| From: | Guillaume Lecanu | Date: | Sat, 03 Apr 2004 03:55:37 +0000 |
| Subject: | Re: XML_Functions | ||
| References: | 1 2 3 4 5 6 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-26989@lists.php.net to get a copy of this message | ||
Le sam 03/04/2004 à 02:44, Alan Knowles a écrit :
> Nice to hear.. - I quite liked the original design, returning strings. -
> this as the default behaviour was very lightweight. I was hoping that
> returning XML_Tree etc. would be optional rather than default..
Why not, i tell you if i can tomorrow.
>
> - one of the not soo highlighted aims of pear is to keep dependancies
> down to a minimum, where feasible... :)
The minimum is XML_Tree of course, but if you don't use the validation
option you doesn't require XML_DTD package.
Bye
>
> Regards
> Alan
>
>
>
> Guillaume Lecanu wrote:
> > Le sam 03/04/2004 à 02:12, Alan Knowles a écrit :
> >
> >> >
> >>
> >>>>- In addition to returning strings, It would nice if it could return
> >>>>XML_Tree / HTML_Template_Flexy_Element / HTML_Common ... etc. elements
> >>>>as well:
> >>
> >> >
> >>
> >>>Why not, but this make dependecies on my packages..
> >>
> >>very much optional deps... - existing package would work pefectly well
> >>without FastCreate...
> >>and FastCreate would work perfectly well without them...
> >
> >
> > I have made a new XML_FastCreate package :)
> > Now, i use directly the XML_Tree structure, all elements are
> > XML_Tree_Node objects.
> >
> > And i have add the support of a DTD. If precised, when you run
> > $x->toXML(), the package make warnings if you have not respected the DTD
> > file.
> >
> > Example :
> >
> > $x = new XML_FastCreate('xhtml1-strict.dtd');
> >
> > $x->html(
> > $x->head(
> > $x->title('Examples of XML_FastCreate'),
> > ),
> >
> > $x->body(
> > $x->div(
> > $x->h1("Examples of PEAR::XML_FastCreate package"),
> >
> > // Each elements are seperated by comma
> > $x->ul(
> > $x->li(
> > $x->span("Make valid XML document easyly")
> > ),
> > $x->li(
> > $x->span("Add control by DTD (with PEAR::XML_DTD)")
> > ),
> > $x->li(
> > $x->span("Each element are XML_Tree_Node object")
> > )
> > )
> > ),
> > )
> > );
> >
> > $x->toXML();
> >
> >
> > It's very simple :)
> > I have 2/3 bugs to fix and i'll propose this package.
> > But for now, i'm late (4h30 in France) so good night :)
> >
> > Regards,
> >
> > PS: Thanks Alan for all your advices about this package !
> >
> >
> >>Regards
> >>Alan
> >>
> >>
> >>
> >>
> >>--
> >>Can you help out?
> >>Need Consulting Services or Know of a Job?
> >>http://www.akbkhome.com
> >
> >
>