Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3795358
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T13:04:18+00:00 2026-05-19T13:04:18+00:00

thanks in advance for any input. I am using struts2 and jquery in this

  • 0

thanks in advance for any input. I am using struts2 and jquery in this app.

I tried to use displaytag for pagination but my tables have images and there wasn’t a way I could make displaytag work with images.

So now I have custom coded pagination which uses <s:subset> which works great so far except that I don’t know how to make it go to another page.

Basically in <s:subset> I just want to change the start attribute and then refresh my JSP. My code evaluates the start attribute correctly with a given page number.

My s:subset tag is like below,

<s:subset source="pageableList.pagedList" count="pageableList.pageSize" start="pageableList.start"  > 
            <s:iterator> 

I think I want to use <s:url> to display my clickable page numbers but I’m having trouble there.

I have my page numbers in a list (which I evaluate in my action class right after my search completes), then in my JSP where I need to display the clickable page numbers, I iterate through the list, displaying the page numbers like below –

<s:iterator value="pageNumList" > | <a href='#'> <s:property/> </a> </s:iterator>

I guess I need to pass the clicked value of page number to the action class, then since the search results are in a list in the action class, without hitting the database again just display the results page with the new value of start attribute.

Any ideas how I might do that? I have been considering using a Decider attribute with <s:subset> but maybe there is a simpler way?

Thanks again for any input.

Regards,
veeCan

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T13:04:19+00:00Added an answer on May 19, 2026 at 1:04 pm

    If you do not want to hit your DB again, cache the results of the initial query in RAM in your Action class (reference a static cache somewhere). Also, you don’t have to go with a cache-all-or-nothing approach — you can cache the first N pages and then when you near the end of the cache, fetch the rest. If you do it right, you can maintain minimum RAM footprint but preserve a snappy user experience that leverages user think time (depends on your app).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using c# .net. Thanks in advance for any help. I have searched
Thanks for any help in advance, I can't wrap my SQL skills around this
thanks in advance for reviewing my post. I've only been using jquery for about
Thanks in advance for any help. I am new to python, but not particularly
Thanks in Advance for reading and answer this question. I got button in asp
Thanks in advance. This is my sample code. Whenever i try to run it
I am using Jquery to change the value of a hidden input to 'True'
I'm using the ADO.Net Entity Framework. To handle input validation I'm trying to use
I'm a beginner, so forgive any stupidity in advance. I'm using Flask (and by
thanks in advance for your help. I am wondering if there is a (design)

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.