XML and it's usage for Themes.
<[email protected]> Wed, 23 Oct 2002 07:25:04 +0100 (IST)
| Newsgroups | gmane.comp.web.encompass.devel |
|---|---|
| Message-ID | <[email protected]> |
Speaking with mh7, we've come to begin thinking about future usages of XML
in themes.
The noticable diffrence will be in it's structure, since it will conform
to XML standards, instead of the custom made .tpl files with no real
requierd formatting.
Namely, alot of new options could also be added.
When using XML, custom tags are quickly able to be made without pre-
defined options. Using this feature, the ability to provide non-hard coded
parts of the portal can be done very easily.
A sample structure for getting a block to be colored would be no more than:
-normal XML structure-
<block section="b1top" color="#FFFFFF">
{$data}
</block>
<block section="b1bottom" color="#000000">
{$data}
</block>
-ending xml-
After this file is created, and stored in the theming xml directories
(In this case, /blocks/theme/xml /blocks/theme/images ect.)
you can then have your block with a line such as this:
<?php
...
<table bgcolor='$b1top' ect.>
...
<table bgcolor='$b1bottom' ect.>
...
?>
The pre-defined structure would be read by either a custom built XML
parsing engine, or by modifing an existing one that currently works.
As far as for actual themes, they would follow the same as above, except
using the engines extended features, it would be possible to create custom
XML parsing options not normally available.
Just a thought. Is it a feasable idea? Or just a "can be done, shouldn't be
done."