I am new to the world of JSF. I am trying to develop a simple program which passes array of books to HTML page. But i am not able to pass the content.
file : index.xhtml
<?xml version="1.0" encoding="UTF-8"?>
<!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:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" >
<h:head>
<link type="text/css" rel="stylesheet" href="WEB-INF/table-style.css" />
</h:head>
<h:body>
<h1>Book Management Table</h1>
<h:dataTable value="#{Book.BookList}" var="b" styleClass="BookDetails-table" headerClass="BookDetails-table-header" rowClasses="BookDetails-table-odd-row,BookDetails-table-even-row">
<h:column>
<!-- column header -->
<f:facet name="header">Book Name</f:facet>
<!-- row record -->
#{b.bookName}
</h:column>
<h:column>
<f:facet name="header">Author Name</f:facet>
#{b.authorName}
</h:column>
<h:column>
<f:facet name="header">Price</f:facet>
#{b.price}
</h:column>
<h:column>
<f:facet name="header">Quantity</f:facet>
#{b.qty}
</h:column>
</h:dataTable>
</h:body>
</html>
The table has been created in output when i checked source code via browser. But the values are not been passed. Thank you