Re: XML over CSS
From: Chris Hope (blackhole_at_electrictoolbox.com)
Date: 07/12/04
- Next message: Lc: "php URL and variables"
- Previous message: Lc: "Re: "\n" in PHP"
- In reply to: Mudge: "Re: XML over CSS"
- Next in thread: Benny Hill: "Re: XML over CSS"
- Reply: Benny Hill: "Re: XML over CSS"
- Reply: Chung Leong: "Re: XML over CSS"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Mon, 12 Jul 2004 16:44:51 +1200
Mudge wrote:
> Thank you. Do you think that generating XML and then using XSL to change
> it into HTML and then using CSS for page layout and display -- do you
> think this makes it easier to separate presentation from business logic
> than just using HTML and CSS?
It depends how you code your PHP. But generally when people code the HTML
output in the PHP you often end up with a lot of HTML and PHP being mixed
up together with database calls in the middle of the HTML output. There's
not necessarily anything wrong with this (and I've done it plenty of times
in the past) but it is nice to separate that stuff from the output. Using
XML/XSL enforces the separation.
There are other methods though, such as using a templated solution like
Smarty (I've never used it myself but seen it mentioned here before).
A lot of your decision really comes down to how much you want to have to
learn. If you choose XML & XSL to do the presentation layer then you're
going to have to learn XSL as well as PHP. An excellent XSL reference book
(if you decide to learn it) is http://tinyurl.com/36jq9
-- Chris Hope - The Electric Toolbox - http://www.electrictoolbox.com/
- Next message: Lc: "php URL and variables"
- Previous message: Lc: "Re: "\n" in PHP"
- In reply to: Mudge: "Re: XML over CSS"
- Next in thread: Benny Hill: "Re: XML over CSS"
- Reply: Benny Hill: "Re: XML over CSS"
- Reply: Chung Leong: "Re: XML over CSS"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|