Home / Interview / JSF :: General Questions

Interview :: JSF

51) How to map Faces Servlet instance in JSF (JavaServer Faces) application?

The configuration of a JavaServer Faces application is done by mapping the Faces Servlet in the web deployment descriptor file a web.xml.

52) What are the Facelets Templates?

It is a tool which provides the facility to implement the user interface. Templating is a useful Facelets feature that allows you to create a page that will act as the base for the other pages in an application. By using templates, you can reuse code and avoid recreating similar pages again and again.

53) How to create Facelets Templates?

Templating is a useful Facelets feature that allows you to create a page that will act as the base for the other pages in an application.

54) What are the Facelets Composite Components?

JSF provides the concept of composite components with Facelets. The Composite component is a special type of template that acts as a component in your application.

55) What are web resources in JSF (JavaServer Faces)?

JSF web resources are the resources which are required for proper rendering in the web application. It includes images, script files, and any user-created component libraries.

56) How to access CSS (Cascading Style Sheets) File in JSF (JavaServer Faces) application?

The <h:outputStylesheet> tag is used to access CSS (Cascading Style Sheets) resource in the web application. You must create a subdirectory inside the resources folder.

57) How to access JS (JavaScript) File in JSF (JavaServer Faces) application?

The <h:outputScript> tag is used to access JavaScript file in the web application. You must create a subdirectory inside the resources folder.

58) How to relocate web resources in JSF (JavaServer Faces) application?

JSF provides a facility to place your resources at any section of your web page and render it to another section. You can relocate your resource by specifying the target attribute.

59)

How to create JDBC (Java Database Connectivity) connection in JSF (JavaServer Faces) application?

You can integrate JSF application to the JDBC. JDBC allows you to store data into the database table.