2 Replies Latest reply on May 11, 2006 1:35 PM by Jeff_Self

    Previous and Next Page links causing problem with Variable

    Jeff_Self Level 1
      I have an app that had a basic search page, a results page, and a details page. My queries are located in a separate cfc file. So I decided to add Previous Page/Next Page links and I used the Next-N records interface out of the ColdFusion wack book.

      Here in lies the problem. In the book, the query is on the same page as the NextN file. Since my query is in a cfc file, when the person submits a form, it calls the results page. The results page invokes the query.

      The result page returns the records without a problem, but when I click on the link for Next page, it blows up. I get an error saying that it couldn't find the Variable StreetNum.

      I know whats happening. The first time the results page is called, the StreetNum variable was passed from the search form. But when I click on Next, it processes the results page again, but this time it doesn't see the form.

      So how would I pass this variable along? I've thought about making it a session variable. But what page would I set this on? I'm a little confused on where it should get passed.


      Here's the query that gets called: