Re: New XSLT class for PEAR
| From: | Christian Stocker | Date: | Mon, 24 Feb 2003 16:31:26 +0000 |
| Subject: | Re: New XSLT class for PEAR | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-13765@lists.php.net to get a copy of this message | ||
On Mon, 2003-02-24 at 17:25, Christian Stocker wrote:
> 3) reading the xml/xsl into php memory and then sending to Sablotron is
> (IMHO) quite stupid, Sablotron can read from the file system. Somehow
> this should be supported, too..
addition to that: I never tested this, but I assume, that it's much
faster to let sablotron read and parse the xml/xslt files directly from
the filesystem, especially if the files are big. I'd assume, that if you
read it first into php-memory, you have the document twice in the
memory, once as flat string and once as dom-tree within sablotron... But
I could be wrong...
chregu
>
> 4) Building a template system around XSLT??? mmmh, doesn't make much
> sense to me ;)
>
> 5) There are other XSLT-Processors in PHP (mainly libxslt, but see 1)
> for that matter)
>
> That's about it. Therefore, my proposal for you: Integrate the
> "send-xslt-to-supporting-browsers" into the existing XSLT-Wrapper (and
> make it optional..) and build your templating-system around this and
> XML_Tree.
>
> chregu
>
>
>
>
> On Mon, 2003-02-24 at 17:11, Dan Kuykendall wrote:
> > I wrote another XSLT class that I hope can be included with PEAR.
> >
> > This class is a wrapper for PHP's XSLT support. Its makes it easier to
> > use XSLT, and also adds a feature which can take a good amount of load
> > off of the server.
> > The class will attempt to discover if the client/browser has a decent
> > XSLT engine. So far it only supports IE 5.5+, but as soon as mozilla
> > fixed a couple things with its XSLT support I will add it.
> >
> > If it decides that the browser has XSLT, then it will just send the XML
> > to the browser and let the browser handle rendering into HTML, and save
> > the server from the hassle.
> > Otherwise it will use PHP's XSLT support to render the HTML which can
> > then be sent to the browser.
> >
> > All the details and the package itself can be found at
> > http://www.kuykendall.org/xmltools/Xslt.html
> >
> > Im planning to add a templating class which will depend on this class as
> > well as PEAR's XML_Tree. It will work like many template classes in that
> > it will allow the user to simply set vars in the class. The template
> > class will handle converting the resulting vars into XML and then go
> > thru the XSLT process. This conversion will also depend on a function I
> > wrote for XML_Tree which enables XML_Tree to automaticly convert an
> > array into its XML nodes, thereby making it super easy to convert an
> > array into XML with just a few commands. The function has been submitted
> > to the XML_Tree maintainers, but can also be found at
> > http://www.kuykendall.org/xmltools/importVar.txt
> >
> > I dont know how the voting process is supposed to work, but I would like
> > to have the class reviewed and opened up for a vote. I have alot I would
> > like to contribute to PEAR.
> >
> > Im working on a completely new version of phpGroupWare which will sit on
> > top of PEAR. Im the founder of phpGroupWare and initially resisted PEAR.
> > However I did not anticipate how well PEAR would turn out and I now am
> > convinced that this is a collection of very quality code, and really
> > want to contribute to this great project.
> >
> > Dan Kuykendall
> --
> christian stocker | bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich
> phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71
> http://www.bitflux.ch | chregu@bitflux.ch | gnupg-keyid
> 0x5CE1DECB
--
christian stocker | bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich
phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71
http://www.bitflux.ch | chregu@bitflux.ch | gnupg-keyid
0x5CE1DECB