I may be missing something, but don’t templates end up putting presentation and functionality in the same place? I don’t have a solution (other than still putting the presentation aspects into css), just trying to see if I get it. I look through templates and I see people showing color schemes and images and how they did the columns. But I also see ways to add this or that function to a site. Is this inevitable, is it the html/css issue just at a higher level? Do I misunderstand something? Or at least suggest a good sangria recipe and I will learn to forget the problem.
-
☆ A M B ☆
- 24,524 Posts
There is such a concept as "optimal". A number of technical concepts fall into the same "grey" area, such as database normalization. There are seven levels of normalization for "correct" database design, but in practical use more than the first two levels are rarely implemented. A strict interpretation of theory is usually quite impractical, if not downright harmful, in practice.
Templates allow for a very high degree of separation of presentation, structure, and function. Actually, MODx templates allow for an even greater degree of granularity, allowing the separation of structure (HTML), presentation (CSS), content (TVs and chunks) and function (snippets and plugins). The content and function are separated with the use of the MODx tags (and plugins); nothing more than the tags are used in the structure so that editors can focus on their content (TVs, including the default document variables such as pagetitle or content) and programmers can focus on their functionality (snippets and plugins). Designers can focus on their structure and presentation (HTML and CSS).
Templates don’t have to contain any content at all (unless you count HTML code). All content can (and usually should) be brought in via MODx tags.