|
11/23 |
2001/7/27-28 [Computer/SW/Languages/Web] UID:21973 Activity:high |
7/27 So what do people here think of Tomcat/Velocity for web application development? Is there a future in it? I'm looking for something more useful than PHP and something that's not Perl. -randal \_ If you are going to go the Tomcat route, I think it is worthwhile taking a look at Struts. JSP is nasty but Struts makes it somewhat usable. -payam \_ What's wrong with traditional Servlets? \_ Separation of the front-end design from the back-end logic is usually considered a good thing. \_ thank you for not capitalizing "good thing" \_ And you can't do this using Servlets because...? \_ Because I'm loath to allow designers to start mucking around with .java files and build scripts. From my experience, it's just too foreign for your average designmonkey. JSP/php/blah files at least look like normal HTML. Plus, today there is reasonable tool support for designers to use. \_ Designers? You mean the artists don't you. The ones who talk about flows and usability and look and feel. My experience has been that we just end up rewriting thier shit anyway. I just use them for icons, style sheets and proofreading. Its all thier english degrees are good for anyway. \_ yeah, you certainly need people to proof-read your stuff. It's spelled "their," and "it's" is the contraction for which you're looking. but with all due respect, coders generally don't seem to be good authorities on usability either. \_ JSP is evil. Velocity is Perlish (ergo crap). Use the real thing: http://freemarker.sourceforge.net |
freemarker.sourceforge.net The most notable improvements are the ability to define functions (methods) in templates, the ability to interpolate variables in string literals, the support for a variable number of macro parameters, and the more intelligent default object wrapper. With this FreeMarker targets a new application domain, which is similar to the application domain of XSLT: transforming complex XML to whatever textual output. FreeMarker is designed to be practical for the generation of HTML Web pages, particularly by servlet-based applications following the MVC (Model View Controller) pattern. The idea behind using the MVC pattern for dynamic Web pages is that you separate the designers (HTML authors) from the programmers. Designers can change the appearance of a page without programmers having to change or recompile code, because the application logic (Java programs) and page design (FreeMarker templates) are separated. Templates do not become polluted with complex program fragments. Although FreeMarker has some programming capabilities, it is not a full-blown programming language like PHP. Instead, Java programs prepare the data to be displayed, and FreeMarker just generates textual pages that display the prepared data using templates. Overview of FreeMarker workflow FreeMarker is not a Web application framework. It is suitable for a component in a Web application framework, but the FreeMarker engine itself knows nothing about HTTP or servlets. As such, it is perfectly usable in non-web application environments as well. Struts), which also let you use JSP taglibs in the templates. OSI Certified is a certification mark of the Open Source Initiative. |