Re: paginator tags

2003-03-07 Thread Ashish Kulkarni
Hi
here is how to define the taglib in web-inf
taglib
taglib-urihttp://jsptags.com/tags/navigation/pager/taglib-uri
taglib-location/WEB-INF/pager-taglib.tld/taglib-location
/taglib


Here is in nutshell all u need to do for setting
paging tablib in jsp
//declare jsp tag in taglib
%@ taglib
uri=http://jsptags.com/tags/navigation/pager;
prefix=pg %
pg:pager maxIndexPages=3
 maxPageItems=10
export=pagerPageNumber=pageNumber 
!--i use cached row set to store the data, resut is a
bean defined, i dont want to build a bean and an array
list of that bean etc to handle paging--
CachedRowSet crs = result.getCachedData();
!-- start your loop to display data from arraylist or
result set --
% while (crs.next())
  {
  %
  pg:item
  %
!-- the code to build table code will go here
--
  /pg:item
!-- logic to get the build the page number and images
so u can do pagin
--
pg:index 

!-- for previos page i use a image here--
pg:prev
 
a href=%= pageUrl %
onMouseOut=MM_swapImgRestore()
onMouseOver=MM_swapImage('left','','../images/en/buttons/arrow_left_on.gif',1)img
name=left border=0
src=../images/en/buttons/arrow_left_off.gif
width=30 height=30 align=absmiddle/a
  /pg:prev 

!-- for page numbers like in google --

pg:pages
 a class=pageNum href=%= pageUrl % %=
pageNumber %/a
 /pg:pages 

!-- for next page--

pg:next
 a href=%= pageUrl %
onMouseOut=MM_swapImgRestore()
onMouseOver=MM_swapImage('right','','../images/en/buttons/arrow_right_on.gif',1)img
name=right border=0
src=../images/en/buttons/arrow_right_off.gif
width=30 height=30 align=absmiddle/a

/pg:next 

/pg:index 
!-- end of pager--
/pg:pager


 
I hope this helps
I am also attaching one of the jsp along this mail for
your reference

Ashish








--- Richard Raquepo [EMAIL PROTECTED] wrote:
 Can you give me actual jsp code on how you used the
 pager tag. i find it
 hard to customize it. thanks
 - Original Message -
 From: Ashish Kulkarni [EMAIL PROTECTED]
 To: Struts Users Mailing List
 [EMAIL PROTECTED]
 Sent: Friday, March 07, 2003 5:36 AM
 Subject: Re: paginator tags
 
 
  Hi
  u may wanna have a look at this
  http://jsptags.com/tags/navigation/pager/index.jsp
 
  it works well for me
 
  Ashish
 
  --- alexj [EMAIL PROTECTED] wrote:
   you may use display tag or struts-el
   here is a sample from JSTL in Action :
   %@ taglib prefix=c
   uri=http://java.sun.com/jstl/core; %
  
   c:set var=totalCount scope=session
   value=100/
  
   c:set var=perPage scope=session
 value=20/
  
   c:forEach
  
   var=boundaryStart
  
   begin=0
  
   end=${totalCount - 1}
  
   step=${perPage}
  
   a href=?start=c:out
 value=${boundaryStart}/
  
   [
  
   c:out value=${boundaryStart}/
  
   -
  
   c:out value=${boundaryStart + perPage - 1}/
  
   ]
  
   /a
  
   /c:forEach
  
   c:forEach
  
   var=current
  
   varStatus=status
  
   begin=${param.start}
  
   end=${param.start + perPage - 1}
  
   c:if test=${status.first}
  
   ul
  
   /c:if
  
   lic:out value=${current}//li
  
   c:if test=${status.last}
  
   /ul
  
   /c:if
  
   /c:forEach
  
   --
   Alexandre Jaquet
   - Original Message -
   From: Jacky Kimmel [EMAIL PROTECTED]
   To: [EMAIL PROTECTED]
   Sent: Thursday, March 06, 2003 9:22 PM
   Subject: paginator tags
  
  
   
Does anyone know how to implement paginator
 tags?
   Ie: you have a list of
   30 items out of 100.  You now want to display
 the
   next 30 and so on.
   
   
   
Also, I am using application.resource for all
   labels.  I want to have a
   name with a trademark symbol as a superscript.
   Anyone know how to do this?
   
   
   
-
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips,
 and
   more
  
  
  
  
 

-
   To unsubscribe, e-mail:
   [EMAIL PROTECTED]
   For additional commands, e-mail:
   [EMAIL PROTECTED]
  
 
 
  =
  A$HI$H
 
  __
  Do you Yahoo!?
  Yahoo! Tax Center - forms, calculators, tips, more
  http://taxes.yahoo.com/
 
 

-
  To unsubscribe, e-mail:
 [EMAIL PROTECTED]
  For additional commands, e-mail:
 [EMAIL PROTECTED]
 
 
 
 
 

-
 To unsubscribe, e-mail:
 [EMAIL PROTECTED]
 For additional commands, e-mail:
 [EMAIL PROTECTED]
 


=
A$HI$H

__
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

paginator tags

2003-03-06 Thread Jacky Kimmel

Does anyone know how to implement paginator tags?  Ie: you have a list of 30 items out 
of 100.  You now want to display the next 30 and so on.

 

Also, I am using application.resource for all labels.  I want to have a name with a 
trademark symbol as a superscript.  Anyone know how to do this?



-
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, and more

Re: paginator tags

2003-03-06 Thread alexj
you may use display tag or struts-el
here is a sample from JSTL in Action :
%@ taglib prefix=c uri=http://java.sun.com/jstl/core; %

c:set var=totalCount scope=session value=100/

c:set var=perPage scope=session value=20/

c:forEach

var=boundaryStart

begin=0

end=${totalCount - 1}

step=${perPage}

a href=?start=c:out value=${boundaryStart}/

[

c:out value=${boundaryStart}/

-

c:out value=${boundaryStart + perPage - 1}/

]

/a

/c:forEach

c:forEach

var=current

varStatus=status

begin=${param.start}

end=${param.start + perPage - 1}

c:if test=${status.first}

ul

/c:if

lic:out value=${current}//li

c:if test=${status.last}

/ul

/c:if

/c:forEach

--
Alexandre Jaquet
- Original Message -
From: Jacky Kimmel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, March 06, 2003 9:22 PM
Subject: paginator tags



 Does anyone know how to implement paginator tags?  Ie: you have a list of
30 items out of 100.  You now want to display the next 30 and so on.



 Also, I am using application.resource for all labels.  I want to have a
name with a trademark symbol as a superscript.  Anyone know how to do this?



 -
 Do you Yahoo!?
 Yahoo! Tax Center - forms, calculators, tips, and more



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: paginator tags

2003-03-06 Thread Roeland Lengers
With regards to your second question:


name.with.trademark=SomeNametrade;

Will get you where you want.
The trade; code is already a tm in superscript. If it's still not
superscripted enough you could try

name.with.trademark=SomeNamesuptrade;/sup

Regards,

Roeland Lengers


Jacky Kimmel [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]...
 
 Does anyone know how to implement paginator tags?  Ie: you have a list
of 30 items out of 100.  You now want to display the next 30 and so on.
 
  
 
 Also, I am using application.resource for all labels.  I want to have
a name with a trademark symbol as a superscript.  Anyone know how to do
this?
 
 
 
 -
 Do you Yahoo!?
 Yahoo! Tax Center - forms, calculators, tips, and more



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: paginator tags

2003-03-06 Thread Ashish Kulkarni
Hi
u may wanna have a look at this
http://jsptags.com/tags/navigation/pager/index.jsp

it works well for me

Ashish

--- alexj [EMAIL PROTECTED] wrote:
 you may use display tag or struts-el
 here is a sample from JSTL in Action :
 %@ taglib prefix=c
 uri=http://java.sun.com/jstl/core; %
 
 c:set var=totalCount scope=session
 value=100/
 
 c:set var=perPage scope=session value=20/
 
 c:forEach
 
 var=boundaryStart
 
 begin=0
 
 end=${totalCount - 1}
 
 step=${perPage}
 
 a href=?start=c:out value=${boundaryStart}/
 
 [
 
 c:out value=${boundaryStart}/
 
 -
 
 c:out value=${boundaryStart + perPage - 1}/
 
 ]
 
 /a
 
 /c:forEach
 
 c:forEach
 
 var=current
 
 varStatus=status
 
 begin=${param.start}
 
 end=${param.start + perPage - 1}
 
 c:if test=${status.first}
 
 ul
 
 /c:if
 
 lic:out value=${current}//li
 
 c:if test=${status.last}
 
 /ul
 
 /c:if
 
 /c:forEach
 
 --
 Alexandre Jaquet
 - Original Message -
 From: Jacky Kimmel [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, March 06, 2003 9:22 PM
 Subject: paginator tags
 
 
 
  Does anyone know how to implement paginator tags? 
 Ie: you have a list of
 30 items out of 100.  You now want to display the
 next 30 and so on.
 
 
 
  Also, I am using application.resource for all
 labels.  I want to have a
 name with a trademark symbol as a superscript. 
 Anyone know how to do this?
 
 
 
  -
  Do you Yahoo!?
  Yahoo! Tax Center - forms, calculators, tips, and
 more
 
 
 

-
 To unsubscribe, e-mail:
 [EMAIL PROTECTED]
 For additional commands, e-mail:
 [EMAIL PROTECTED]
 


=
A$HI$H

__
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: paginator tags

2003-03-06 Thread Richard Raquepo
Can you give me actual jsp code on how you used the pager tag. i find it
hard to customize it. thanks
- Original Message -
From: Ashish Kulkarni [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Friday, March 07, 2003 5:36 AM
Subject: Re: paginator tags


 Hi
 u may wanna have a look at this
 http://jsptags.com/tags/navigation/pager/index.jsp

 it works well for me

 Ashish

 --- alexj [EMAIL PROTECTED] wrote:
  you may use display tag or struts-el
  here is a sample from JSTL in Action :
  %@ taglib prefix=c
  uri=http://java.sun.com/jstl/core; %
 
  c:set var=totalCount scope=session
  value=100/
 
  c:set var=perPage scope=session value=20/
 
  c:forEach
 
  var=boundaryStart
 
  begin=0
 
  end=${totalCount - 1}
 
  step=${perPage}
 
  a href=?start=c:out value=${boundaryStart}/
 
  [
 
  c:out value=${boundaryStart}/
 
  -
 
  c:out value=${boundaryStart + perPage - 1}/
 
  ]
 
  /a
 
  /c:forEach
 
  c:forEach
 
  var=current
 
  varStatus=status
 
  begin=${param.start}
 
  end=${param.start + perPage - 1}
 
  c:if test=${status.first}
 
  ul
 
  /c:if
 
  lic:out value=${current}//li
 
  c:if test=${status.last}
 
  /ul
 
  /c:if
 
  /c:forEach
 
  --
  Alexandre Jaquet
  - Original Message -
  From: Jacky Kimmel [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Thursday, March 06, 2003 9:22 PM
  Subject: paginator tags
 
 
  
   Does anyone know how to implement paginator tags?
  Ie: you have a list of
  30 items out of 100.  You now want to display the
  next 30 and so on.
  
  
  
   Also, I am using application.resource for all
  labels.  I want to have a
  name with a trademark symbol as a superscript.
  Anyone know how to do this?
  
  
  
   -
   Do you Yahoo!?
   Yahoo! Tax Center - forms, calculators, tips, and
  more
 
 
 
 
 -
  To unsubscribe, e-mail:
  [EMAIL PROTECTED]
  For additional commands, e-mail:
  [EMAIL PROTECTED]
 


 =
 A$HI$H

 __
 Do you Yahoo!?
 Yahoo! Tax Center - forms, calculators, tips, more
 http://taxes.yahoo.com/

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]