[Zope3-dev] IMPORTANT RFS: Through the Web Site Development

Jeffrey P Shell jeffrey@cuemedia.com
Mon, 13 Jan 2003 16:37:38 -0700


On Monday, January 13, 2003, at 04:11  PM, Luciano Ramalho wrote:

> On segunda-feira, jan 13, 2003, at 19:48 America/Sao_Paulo, Jim Fulton 
> wrote:
>
>>> Yep, be amazed. I'll happily wax on why people use DTML if you want 
>>> my 2 cents
>>
>> Please. I really would prefer that people new to Zope start with ZPT.
>> I'm willing to consider adding things to ZPT within reason and if
>> necessary to make this so.
>>
>
> Yes, some things could be added to ZPT to make it more attractive to 
> beginners. An easier way to do batching is a good example.
>
> But I don't think adding functionality to ZPT is the answer. The DTML 
> epidemic must be stopped by education!
>
> People must learn:
>
> 1) that embedding logic in your templates is BAD
>     (this is not obvious if all you've ever seen is PHP);
>
> 2) that learning a little Python is easy and fun;
>     (this not obvious if the last language you learned was badly 
> designed -- no need to mention names here)

If you want, you can teach them that Python Scripts are just like PHP 
pages!  Since most PHP seems to include::

   echo "<td>" + data + "</td>"

in a language that's supposed to integrate into HTML, you can say 
"well, a Python Script is just like a PHP page that doesn't have to 
start with <?php"  ;)

Tell them to::

   print "<td>%s</td>" % data
   return printed

Then, after they realize that doing that gets pretty old pretty 
quickly, then you can teach them the joys of structuring data for 
dynamic HTML formatting with page templates :).