phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Phpgroupware-developers] My new XSL Template class


From: Dan Kuykendall
Subject: Re: [Phpgroupware-developers] My new XSL Template class
Date: Fri, 23 Aug 2002 16:34:08 -0700
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1b) Gecko/20020721

OH!
Keep in mind that this code was done in 5 hours. Its not ready to drop into phpGW and start using it. It does seem to be pretty stable and functional and Im happy with the code at this stage.

Also there are some debugging things you can do with the index.php

http://yourserver/phpgw_xslt/index.php?show=xml
Will show you the XML data that I generate from the vars passed to the class.
http://yourserver/phpgw_xslt/index.php?show=xsl
Will show you the merged XSL result of all the files added via add_file()

http://yourserver/phpgw_xslt/index.php?show=source
Will show you the source of the index.php

http://yourserver/phpgw_xslt/index.php?show=classsource
will show you the source of the class file.


If your interested in viewing this but cant get xslt working on your server I have my up (for now) at
http://24.55.40.133/phpgw_xslt/index.php
You can also use all the above mentioned debugging stuff
example:
http://24.55.40.133/phpgw_xslt/index.php?show=xml

You can also look at the couple xsl files there.
They are  phpgw.xsl, top.xsl, left.xsl, todo.xsl and bottom.xsl

Seek3r

Dan Kuykendall wrote:
This is the XSL Template class I have been talking about to a few people. Now that I have finally gotten the code out of my head and only file I wanted to get some eyeballs on it.

Basicly just unzip this into a dir under your webroot. You will need PHP's XSLT support enabled for this to work at all.

The idea is that this will replace our use of PHPLIB's tpl based template system. XSL can handle most if the UI layer all on its own with this template class. In phpGW the UI layer would basicly just make the request to the bo class, decide which xsl files are needed and do template->add_file() for them. Then it would take the return data from the bo and pump it into template->set_var().

The template class will auto convert these arrays into XML, will merge all the required XSL files into a single xslresult and will then use PHP's XSLT to convert it into HTML.

XSL can do all the loops thru the data to generate the interface we are used to.

My goal is to start becoming forward compatible with where the industry is moving. XSL is a great technology and can get us pushed into the XML world and move our code to work better in the web services sector.

Seek3r





reply via email to

[Prev in Thread] Current Thread [Next in Thread]