Solved

jsp and pager tag library

Posted on 2006-11-30
2
602 Views
Last Modified: 2010-05-18
Hi,

Im trying to set a value (maxPageItems) in pager tag library by using a session variable but I am getting the error Attribute amountOfPages has no value even though the attribute does have a value.

This is the line that causes the error:
maxPageItems="<%=session.getAttribute("amountOfPages")%>"

But this works:
maxPageItems="<%=5%>"

Here a snippet from the jsp file:
<pg:pager index="center"
              maxPageItems="<%=session.getAttribute("amountOfPages")%>"
              maxIndexPages="5"
              export="currentPageNumber=pageNumber"
              url=""
              scope="request">
      \="style"/>
      <pg:param name="position"/>
      <pg:param name="index"/>
      <pg:param name="maxPageItems"/>

Thanks
0
Comment
Question by:ram_os
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 

Author Comment

by:ram_os
ID: 18044240
got it,

for anyone whos interested:

maxPageItems="<%=session.getAttribute(\"amountOfPages\")%>"

I think its because the tag library is based on an older jsp implementation.
0
 

Accepted Solution

by:
PashaMod earned 0 total points
ID: 18049907
Closed, 200 points refunded.
PashaMod
Community Support Moderator
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Justin
In light of the WannaCry ransomware attack that affected millions of Windows machines, you might wonder if your Mac needs protecting. Yes, it does and here is how to do it.
Make the most of your online learning experience.
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question