At 15:42 2000-11-24, you wrote:
>ingo schuster wrote:
> >
> > Hi,
> >
> > I checked in some JSP templates that can be used as an alternative to the
> > ecs Layouts/Navigations. Regard this as an proposal, I know that JSPs are
> > not the preferred apache templating system and Raphael is working on a
> > Velocity based solution, however I think there might be people that will
> > want to use JSPs.
> > In short: We haven't discussed this on the list before, I just added it to
> > the CVS so that you can test it easily. If you don't like it at all, I'll
> > revmove the changes of course.
> >
>
>+1.
>What I'll work on as soon as I finish up my clean up work is to
>allow the use of a template system within the Portlet/PortletController/
>PortletControl objects.
>Providing Velocity/Webmacro templates for the screen and navigations
>should be pretty straightforward as we only need to use what's working
>in Turbine.
>
> > What I did:
> >
> > * I added a JetspeedJspService (basically that's the same as the
> > TurbineJspService, however I had some problems with how the template pathes
> > were used. I asked the author of the TurbineJspService to change it and if
> > he does, we can go back to the "standard" TurbineJspService.)
> > The JspService has some supporting java beans that can be called from
> > within a Jsp
> >
> > * I added a JetspedJspLayout
> >
>
>Why can't we just use the standard JspLayout ?

We shouldn't need to use this, your right. However, the standard JspLayout 
assumes that the layout template is already set, but the 
"services.TurbineTemplateService.default.layout.template" key isn't 
evaluated. As I'm not sure what this key is meant to be for, I introduced a 
new one ("services.JspService.default.layout") and this value is used to 
set the template in JetspeedJspLayout:

         String templateJsp = TurbineResources.getString( 
"services.JspService.default.layout","/default.jsp");
         data.getTemplateInfo().setLayoutTemplate( templateJsp );

If you don't do this, you get a 404 error, "/layoutsnull not found" - this 
has been reported on the turbine list several times, however I haven't 
figured out yet how it's dealt with properly. I want to clean this (as soon 
as I find more time...)

ingo.

> > * I added a templat/jsp directory to the content directory, containing a
> > layout and navigation JSPs
> >
> > * I added a few lines in the TurbineResources.properties (as comments)
> >
> > How to use it:
> >
> > 0. get the new code
> >
> > 1. copy the content/template directoy to the content of you tomcat 
> installation
> >
> > 2. change/enable following keys in your TurbineResources.properties:
> >
> >     layout.default=JetspeedJspLayout
> >     page.default=JspPage
> > 
> 
>services.JspService.classname=org.apache.jetspeed.turbine.services.jsp.JetspeedJspService
> >     services.JspService.templates=/content/templates/jsp
> >     services.JspService.default.layout=/default.jsp
> >     services.TurbineTemplateService.default.navigation=BaseJspNavigation
> >     services.TurbineTemplateService.default.screen=BaseJspScreen
> >
> > Consequences:
> >
> > The ecs layout and navigations are replaced by respective JSP pages. The
> > screen is still the same, i.e. for now the screen still does ecs based
> > aggregation.
> > We should get rid of the ecs screen sometime as well, but i think the
> > templates are already an improvement: HTML templates can be modified easily
> > without changing code. So it's much easier for an admin/web designer to
> > modify the appearance of the portal. Also, we can get rid of quite a few
> > keys in the property files, things like logo, welcome message, etc. are set
> > directly in the templates.
> > Of course, there are other popular templating systems (webmacro, velocity)
> > and we should provide templates for more than one.
> >
> > So please try it and tell me what you think about it. I hope it is ok that
> > I just added the files to CVS  - if you don't enable it in TR.P, there
> > won't be any effect on the other code.
> >
>
>I've not tested it yet but it's bound to be an improvement over what is
>currently in Jetspeed.
>
>--
>Rapha�l Luta - [EMAIL PROTECTED]
>
>
>--
>--------------------------------------------------------------
>Please read the FAQ! <http://java.apache.org/faq/>
>To subscribe:        [EMAIL PROTECTED]
>To unsubscribe:      [EMAIL PROTECTED]
>Archives and Other:  <http://marc.theaimsgroup.com/?l=jetspeed>
>Problems?:           [EMAIL PROTECTED]



--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://marc.theaimsgroup.com/?l=jetspeed>
Problems?:           [EMAIL PROTECTED]

Reply via email to