XML Authors: Jason Bloomberg, Asim Saddal, Greg Schulz, Richard Schwendiman

Blog Feed Post

Eclipse Kepler 4.3.1 Error in New Facelet Template

As part of my class preparation I have been writing blog entries on setting up a JEE 6 web profile Maven projects in Eclipse and in NetBeans using the TomEE server. Once I got that working I proceeded to try out a tutorial from Eclipse called the JSF Tools Tutorial – JSF 2.0 that is found in the Eclipse help system.

Create a new project based on my previous blog “Creating JavaServer Faces Maven Managed Projects with Eclipse” and not as described in the tutorial. Jump to the section entitled “Create Facelets template pages”. At this step you are instructed to create a New Facelet Template named BasicTemplate.xhtml. The code that is generated is not what appears in the tutorial.

This is not a problem because the tutorial provides the code and you can just cut and paste it into your BasicTemplate.xhtml file. There is one line that I wanted to leave as is:

<ui:debug hotkey="x" 

The problem was that this line gets a warning symbol in the editor that states that there is an EL syntax error. After some research I discovered the following. In the web.xml file there is the following entry:


This is a description of the current stage of the project. In this case it is Development. The other possible values are UnitTest, SystemTest, Production and Extension.

The <ui:debug> tag is referring to a parameter no longer used called FACELETS_DEVELOPMENT. So I changed the tag to:

<ui:debug hotkey="x" 

This was not sufficient because there are four possible stages. A little more research uncovered the solution as found at JSF Toolbox

<ui:debug hotkey="x" 
eq 'Development'}"/>

With this change the tutorial project’s errors or warnings were removed and it ran as expected. When viewing the pages in the browser you can press Ctrl-Shift-X to get to the JSF debugging windows. Cool!




Read the original blog entry...

More Stories By Ken Fogel

In 1980 I bought for myself the most wonderful toy of the day, the Apple ][+. Obsession followed quickly and by 1983 I was writing software for small and medium sized businesses in Montreal for both the Apple and the IBM PC under the company name Omnibus Systems. In the evenings I taught continuing education courses that demystified the computer to the first generation of workers who found themselves with their typewriter on the scrap heap and a PC with WordStar taking its place. In 1990 I was invited to join the faculty at Dawson College in the Computer Science Technology program. When I joined the program the primary language was COBOL and my responsibility was to teach small systems languages such as BASIC and C/C++. Today I am now the chairperson and program coordinator of the Computer Science Technology program at Dawson. The program's primary language is Java and the focus is on enterprise programming. I like to write about the every day problems my students and I face in using various languages and platforms to get the job done. And from time to time I stray from the path and write about what I plan to do, what I actually get around to doing, and what I imagine I am doing.