I am writing an app which allows users to search a database. I have put together some routines which do the searches, accepting several parameters and returning the data in XML. The data is then transformed to HTML using XSL files. As with most searches of this nature, I wish to paginate the results. Currently, the procedures that return the XML accept a couple of parameters for page size and number, and return the data for the requested page only. Data on the current page number is included in the XML as an attribute of the top level "resultslist" node.
The question is: where should the code that generates the "Previous Page, Next Page" links be placed? I could put it in the ASP page that handles the search, after the XML is transformed to HTML, or I could put it in the XSL file. I've tried to put it in the XSL file, but I've been having problems - I wanted to include links to individual pages, to produce a navigation bar along the lines of:
< Prev Page - 1 2 3 4 5 6 7 8 9 10 - Next Page >
but I can't work out how to do the specific page links in the center. Please can someone give me some suggestions on this before I am forced to abandon the whole XML thing!
Thanks
Jonathan
j.w.george@virginnet.co.uk
Working against: Visual Basic 6, Access 97, Visual Interdev 6, VBScript, Active Server Pages, SQL Server 6.5, Oracle 7
The question is: where should the code that generates the "Previous Page, Next Page" links be placed? I could put it in the ASP page that handles the search, after the XML is transformed to HTML, or I could put it in the XSL file. I've tried to put it in the XSL file, but I've been having problems - I wanted to include links to individual pages, to produce a navigation bar along the lines of:
< Prev Page - 1 2 3 4 5 6 7 8 9 10 - Next Page >
but I can't work out how to do the specific page links in the center. Please can someone give me some suggestions on this before I am forced to abandon the whole XML thing!
Thanks
Jonathan
j.w.george@virginnet.co.uk
Working against: Visual Basic 6, Access 97, Visual Interdev 6, VBScript, Active Server Pages, SQL Server 6.5, Oracle 7