This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Hi I am trying to paginate a .xhtml using jquery pagination plugin, but in this case me would like retrieve a value from the DDBB->BackBean an int value, and
in function of this value it shows the equivalent number of buttons to that number.
I mean if it retrieves 4 the show four pages.
The way I am using I suppose it´s not the better way then I am going to explain it here.
I have several fields (VARCHAR) in a DDBB then I retrieve the values which are not null, and I have a pagination plugin query which show as buttons as
<div class="result"> there are in the .xhtml.
The bizarre trick which I am using is as follows: if it retrieve 1 this way , then it calls the file 1.xhtml which shows the elements from the field 1 in the DDBB, and it shows just one button from the pagination plugin.
If it retrieves field 2 in the DDBB then it shows the elements from the DDBB field two and so on.
Obviusly it creates a huge file when it retrieves a 100 value from DDBB, also the performance is not very good.