From: <lu...@ne...> - 2002-09-17 19:31:32
|
Kenzaburo Ito wrote: >>The only difference now is, that you've got B) and C) in the same file, >>whereas with templates (and I'm not talking about using a template >>system now) you would have something like "view_bug_prepare.php" that >>gets all the data and includes >>$current_template_path.'/view_bug_page.php'); at the end, which displays >>the data. That would be a pure php template without having to rely on an >>external package. > > > I'm not high on this because it splits even more files out which means even > more places you have to look to fiddle with code. This can be mitigated if we > always name the file with a _prepare suffix. Currently I find 54 _page.php files which, I assume, are the only ones who display data and would be the candidates to be "templated". We would need a lesser number of _prepare.php files, because pages like: bug_update*.php print_bug_page.php and view_bug_*.php could be served by just one _prepare page that switches ( $the desired output ). Maybe others which display the same base data can be grouped together as well. I didn't check thoroughly. The templates wouldn't call any functions apart from "echo" and would only use an occasional "if" statement now and then. >>Agreed, my reason for using a template system instead of php is, that >>I'd like to keep my standard developers/tinkerers, who know HTML, away >>from the code / SQL. > > This isn't the set of users that our code is targeted at. I'd rather design > for the casual developer who needs some tweaks that will extend beyond simple > formatting changes. OK, agreed > Plus it increases the > amount of background knowledge needed enormously. That's not true. Increase yes, enormously no. > Anyway, what's wrong with telling display people to just ignore code below a > certain comment? Nothing, as long as the do it :-) > I think we'll take it to the level that Julian describes and if we find out > weneed full templating we can do that later on. OK. To separate everything into HTML & function calls is the most important part. Templates would then be a quite easy next step. Greetings - Lübbe |