?
Solved

Servlet Template Engines.

Posted on 2003-03-12
10
Medium Priority
?
630 Views
Last Modified: 2013-11-24
Hello
I am working on Java servlets for last 6 months or so using them as webdevelopment tool. Right now i am using traditional approach with servlets where logic and presentation is combined and there is a great mix up.I heard about the Template Engines, they make the task easier for developers by separating logic from presentation. I had a few Template engines like JByte and webmacro but i dont know exact utilization of these template engines.I need to know , how i can effectively use these template engines with my servlets , are there any alternative and better tools available , can we do it with servlets or is this just for JSP only. I have seen Smarty class for php and i really like that. Can i find some working examples any where on net which show exact utilization of these Template Engines with Servlets(Servlets only) becuase JByte and WebMacro donot have working examples to show their utilization with servlets , although they have it with the JSPs
                                Thanks  
0
Comment
Question by:ksj786
10 Comments
 
LVL 4

Expert Comment

by:thanassis
ID: 8118024
0
 

Author Comment

by:ksj786
ID: 8118070
that is specific to JSP. I need something for Servlets
0
 
LVL 1

Expert Comment

by:ayeen
ID: 8118328
you might want to check this out:

http://www.jguru.com/faq/Struts
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 35

Expert Comment

by:TimYates
ID: 8118333
> I have seen Smarty class for php and i really like that.

PHP is like JSP too...

All you have with servlets on their own, is XSLT

Generate your content as XML, then blend it with a stylesheet

AFAIK anyway...
0
 

Author Comment

by:ksj786
ID: 8118351
that is specific to JSP. I need something for Servlets
0
 

Expert Comment

by:spangleweed
ID: 8119285
You could also try Velocity from Apache - this is
a pretty nice way of doing things very much like
JSP - but totally separates logic and presentation ..

http://jakarta.apache.org/velocity/

This is very easy to use - instead of writing a JSP
or normal servlet you extend from VelocityServlet then
post any variables you wish into the velocity context
.. the templates can then access them with a simple
template language ..

I can provide more info if you require, and examples.
0
 

Author Comment

by:ksj786
ID: 8127344
can you show me examples of velocity?
0
 

Expert Comment

by:CleanupPing
ID: 9058751
ksj786:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
LVL 35

Expert Comment

by:girionis
ID: 9714366
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

- To be PAQed and points refunded.

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

girionis
EE Cleanup Volunteer
0
 

Accepted Solution

by:
YensidMod earned 0 total points
ID: 9766394
This question is PAQed  and no points refunded (of 125).

YensidMod
Community Support Moderator
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
A solution for Fortify Path Manipulation.
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
Suggested Courses
Course of the Month9 days, 3 hours left to enroll

621 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question