The attachment would help... I just saw your other emails, I'll reply
shortly.
Ken
Ken Paulsen wrote:
>
> Hi Todd,
>
> The jsftemplating page I referred you to
> (https://jsftemplating.dev.java.net/tutorials/page.html) describes
> what is needed to extract the files needed to use components from
> Creator. Once you have these files, you can use them in your JSF
> environment w/ Facelets, etc. I "think" Facelets also requires the
> TLD, which isn't mentioned in this document. I think the tld is in
> webui.jar, I wouldn't think you'd need to extract it, though... but
> perhaps this is a Facelets requirement? This page also described where
> to get some of the documentation for the components (webui-doc.zip).
>
> The JSFTemplating project is very similar to Facetlets in many ways,
> but works much differently and has some different strengths. It
> supports 2 formats for defining pages, 1 is an XML based approach, the
> other is an HTML-like approach that attempt to simplify things more.
> One of the biggest (in my opinion) features of JSFTemplating is it's
> use of "handlers" for processing events. These promote better
> code-reuse and simplify development.
>
> In regard to TLD's, JSFTemplating doesn't require them. It does,
> however, require a "Factory" class for instantiating a component. This
> provides a way of customizing components based on your needs. For
> example, you can have a factory that takes in parameters (i.e.
> database table names, fields, etc.) and configures a DataProvider for
> your table so that you don't have to write any Java code for each
> table that you want to use. Or... you can use the default factories
> that are provided that include every feature that is published via the
> TLD's. The TLD's themselves aren't used b/c that is a JSP concept that
> describes what options are available... JSFTemplating makes all
> options available automatically and doesn't need to know about them
> ahead of time. This does leave it up to the developer, however, to
> know what options they need (the component documentation is important).
>
> If you want to try the Tree out in a JSFTemplating based project,
> follow the setup instructions on the site (basically create a simple
> web app w/ the jsftemplating and creator jars in the WEB-INF/lib).
> Then drop the attached file into your app.
>
> Let me know if you have more questions...
>
> Ken
>
> Todd Patrick wrote:
>> First of all, thanks Ken for pointing this out to me.
>>
>> I currently have a project that has the following:
>>
>> Server: Tomcat 5.0.28
>> Database: Oracle 10g
>> JSF 1.1
>> Facelets 1.1.11
>> JSTL
>> Spring
>> Acegi-Security
>>
>> Right now, I am running just fine with no problems. However, I need a
>> Tree and Tab component due to project requirements. The Tree component
>> in the webui.jar from SJSC2 would be perfect, however I was having a
>> heck of a time adding it to my project.
>>
>> I'd add the necessary .jars, and added the following to my page:
>>
>> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
>> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
>> <html xmlns="http://www.w3.org/1999/xhtml"
>> xmlns:ui="http://java.sun.com/jsf/facelets"
>> xmlns:h="http://java.sun.com/jsf/html"
>> xmlns:f="http://java.sun.com/jsf/core"
>> xmlns:rave="http://http://www.sun.com/web/ui>
>> <ui:composition template="/common/template.xhtml">
>>
>> <ui:define name="title">Petro Admin: EAI/GFT</ui:define>
>>
>> <ui:define name="body">
>> <rave:staticText id="statictext1" text="some text to
>> display" />
>> </ui:define>
>> </ui:composition>
>> </html>
>>
>>
>> However, this didn't work at all, what would happen is nothing would be
>> rendered in the browser, but viewing the source would display:
>>
>> <rave:staticText id="statictext1" text="some text to display" />
>>
>> Thus, the component wasn't rendered. I downloaded examples and wrapped
>> the rave:staticText in it's own rave:form.
>>
>> Plus, I tried nesting the rave:staticText component in:
>>
>> <ui:page>
>> <ui:html>
>> <ui:head id="head" title="Test text page" />
>> <ui:body>
>> <ui:form id="form1">
>>
>> That didn't work either...
>>
>> So, back to my original question, I downloaded jsftemplating.jar and ran
>> jar -xvf to view the contents, I can't find any TLD information?
>>
>> How do I use the components offered?
>>
>> I looked at the layout.dtd, I *think* the only components offered are:
>>
>> Resources
>> ComponentTypes
>> HandlerDefinitions
>> - InputDef
>> - OutputDef
>> event
>> - handler
>> - input
>> - outputMapping
>> layout
>> - if
>> - foreach
>> - while
>> - facet
>> - staticText
>> - component
>> - option
>> - list
>> - event
>> - markup
>> - attribute
>>
>> Insight would be appreciated on how the components are supposes to be
>> used.
>>
>> Thanks!
>>
>> --Todd
>>
>> Todd Patrick Web Developer DTN 9110 West Dodge Road, Suite 200 Omaha,
>> NE 68114
>> todd.patrick_at_dtn.com Phone: 402-255-8155 Fax: 402-255-8825
>> www.dtn.com DTN Smarter Decisions
<rave:page id="page">
<rave:html id="html">
<rave:head id="head" title="$resource{i18n.peTree}" />
<rave:body>
<rave:form id="form">
<rave:tree id="tree" text="Example Tree" url="/wherever.jsf" imageURL="images/someimage.gif" target="targetFrame" clientSide="#{true}">
<rave:treeNode id="treeNode1" text="Tree Node 1" text="Tree Node 1" url="/wherever.jsf" imageURL="images/someimage.gif" target="targetFrame" />
<rave:treeNode text="Tree Node 2">
<rave:treeNode text="Tree Node 3" />
<rave:treeNode text="Tree Node 4">
<rave:treeNode text="Tree Node 5" />
</rave:treeNode>
</rave:treeNode>
<rave:treeNode text="Tree Node 6" />
</rave:tree>
</rave:form>
</rave:body>
</rave:html>
</rave:page>