Hi Serg, > He show me a MANNINGish book Web Development with JavaServer Pages by DUANE K. FIELDS and > MARK A. KOLB where MVC have been discussed in chapter 8 Architecting JSP applications (I'm sorry > for JSP offtopic, but it relates to subj) and I allow myself to cite pp. 212-213: > [cite] > The presentation layout tier is not concerned with how the information was obtained, or from where. Its > responsibilities lie only in displaying the information itself, while delegating any other activity up the > chain to other tiers. For example, in an application which involves submitting a search query through > a web form only the form itself and the corresponding results are the responsibility of the presenta-tion > layer. What happens in between, the processing of the request and the retreival of the results, is not. > [/cite]
I completely agree, this is exactly what H::T does. Here is most of the citation with the word template stuck in: The template is not concerned with how the information was obtained, or from where. *snip* For example, in an application which involves submitting a search query through a web form only the form iteself and the corresponding results are the responsibility of the template. What happens in between, the processing of the request and the retreival of the results, is not. Works perfectly. > [cite] > This tier (CONTROL - rem. by SV) is also responsible for making decisions among multiple > presentations, when available. If a user�s language, locale, or access level dictates a different > presentation, this decision is made in the control layer. For example, an administrator might > see all of the data from a database query, while an end user might see an alternate, more > restrictive results page. > [/cite] I completely agree, my cgi script determines which of my many templates it is going to use... "responsible for making decisions among multiple presentations, when available." Either it chooses a completely seperate template, or it sets a boolean variable in the template data. If you have a TMPL_IF in your template that is used to show form A or form B based on a TMPL_IF it isn't the view (H::T) that decides which to show... the controller and model (your cgi) provide the data to the template, so the cgi is the one making the decision. The template is merely displaying the the given data based on the given data. If any piece of the MVC paradigm isn't being followed in an application that uses HTML::Template, it's only in the Model or the Controller, which really isn't in Mr. Tregar's scope. :) Kenny Smith JournalScape.com ------------------------------------------------------- This sf.net email is sponsored by: OSDN - Tired of that same old cell phone? Get a new here for FREE! https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390 _______________________________________________ Html-template-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/html-template-users
