Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Mastering Java EE Development with WildFly

You're reading from   Mastering Java EE Development with WildFly Create Enterprise-grade Java applications with WildFly

Arrow left icon
Product type Paperback
Published in Jun 2017
Publisher Packt
ISBN-13 9781787287174
Length 468 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
 Stancapiano Stancapiano
Author Profile Icon Stancapiano
Stancapiano
Arrow right icon
View More author details
Toc

Table of Contents (26) Chapters Close

Title Page
Credits
About the Author
About the Reviewers
www.PacktPub.com
Customer Feedback
Preface
1. Introducing Java EE and Configuring the Development Environment FREE CHAPTER 2. Working with Dependency Injection 3. Persistence 4. Implementing Business Logic 5. Working with Distributed Transactions 6. Creating REST Services 7. Implementing WebSockets 8. Working with Messaging 9. Implementing a Mail Client 10. Asynchronous REST 11. Asynchronous EJB 12. Batches and Workflows 13. Working with Servlets and JSP 14. Writing a JSF Application 15. Sharing the Web Sessions 16. WildFly in Cloud 17. Share your Data 18. Deployment 19. Working with OSGi

Working with Facelets


Facelets is a historical open source project written to manage web graphic templates and other utilities to write better web applications. It was started by the Apache community and is now integrated in JSF, so all its baggage can be used inside the application servers. The version supported by WildFly 10 and all Java EE 7 compliant application servers is 2.2. It is the candidate to write web templates, custom functions, and custom tags.

Web templates

Web templates allow us to create portions of pages that can be included several times in other pages. The common uses for them are the header and the footer of a website. We looked at the pages of Rubia Forums earlier. Here's the category page:

The breadcrumbs at the top are a header that can be shown on several pages. The same thing goes for the Powered by image at the bottom. Now, see how to implement the header with the breadcrumbs starting with the category page:

<div
...
xmlns:ui="http://java.sun.com/jsf/facelets"...
lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime
Visually different images