XSL output using ASP

Discussion in 'ASP General' started by thomas, May 19, 2005.

  1. thomas

    thomas Guest

    This problem has been bothering me for a couple of days now. I'm trying to
    get a small xml based search engine to output 20 results on one page then 20
    on the next page when you click a link and so on. I've got it sort of
    working to the extent that the first first page outputs 20 results but when
    I click next the next 20 results aren't displayed, to see what I mean click
    the following link, press search (without entering anything) and then click
    next page.

    Here are the files I use to try and achieve this in text form so they can be
    viewed easier.
    search.asp http://www.madtim67.com/guitar/temp/search.txt
    next.asp http://www.madtim67.com/guitar/temp/next.txt

    search.asp does what it's supposed to, it takes text entered into the text
    field of my form, splits it up into a maximum of 5 words (to search
    individual words) and passes them onto search_results.xsl which again seems
    to work properly because it outputs the first 20 results. I also passed the
    "full" string onto this page as well because I thought it would be easier to
    pass that on later as opposed to 5 individual words.

    <xsl:param name="text0" />
    <xsl:param name="text1" />
    <xsl:param name="text2" />
    <xsl:param name="text3" />
    <xsl:param name="text4" />
    <xsl:param name="full" />
    <xsl:param name="startPos" select="1" />
    <xsl:param name="recordsPerPage" select="20" />
    <xsl:param name="endPos" select="$startPos + $recordsPerPage" />

    I then try to pass the "full" string and "startPos" to the next.asp page
    using the line
    <a href="next.asp?id=full&amp;startPos={$endPos}">next page</a>

    This is where the process breaks down.

    Any Ideas?
    thomas, May 19, 2005
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Similar Threads