I think I'm kinda getting the point - separate html from code. Seems I was expecting to write too much html in my code. However, to get it all clear, plz give your comments on the following practical example:
I'm trying to build an online subscription form which would -simply- ask for first name, last name and the reason of contacting me (which has to be chosen from a select box). The idea is to build a couple of templates which would give my site new looks randomly (chosen by the user)
As I see it now, I define a template wich holds the entire form, call the template from the php code and just present it. No assigning has to be done (unless I would eventually want them to be able to change the values and thus parse defaults from my db in the form, but that is not the issue right now).
However -if I'm right till now- I can't figure out whether I would go (in reality, the form is bigger) for a static selection box (and if I change the possibilities, change all templates) or dynamicly from code. My template would only hold {SELECTION_BOX} and the real code would be assigned.
What would be the best way? Any more ideas ?