• Post Reply Bookmark Topic Watch Topic
  • New Topic

pagination jquery dinamically  RSS feed

Dura Hurtado
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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.

¿Anyone knows a better way to do that?

I would appretiate it a lot.


  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!