On Mon, Jul 7, 2008 at 9:51 AM, Mayer, Jonathan <[EMAIL PROTECTED]> wrote:
> Hiya all,
>
> I have coded a PHP site on an intranet which forms a MySQL query based on
> multiple inputs on a large form. The form results are POSTed back to itself,
> and query is formed, and the results are returned from the database and
> echoed.
>
> I am looking to set up a basic paging system (back/next, jump to page 3,
> etc) in order to limit results for efficiency.
>
> The problem I get is that my "next" link - something like
> href='resultspage.php?page=2' - naturally reloads the page without all the
> POST variables it needs to recreate the query.
>
> Is there some way of forcing the page to remember and reload the POST
> variables when clicking "next"? Or, if that's difficult, can anyone suggest
> a good way of addressing this problem without too much recoding? I'm sure
> there must be a neater way of doing it then simply passing 30 or so
> variables using GET.
>
> Many thanks in advance.
> Jon.
>
> Jonathan Mayer
> Motion Capture Studio Manager
> TT Games (www.ttgames.com)
> Email: [EMAIL PROTECTED]
> Tel: 01565 757357 Mob: 07814 973885
> Address: Traveller's Tales, Canute Court, Toft Road, Knutsford, Cheshire,
> WA16 0NL
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>

Two semi-quick solutions:

1) Change your paging links to be inside a single form so that when
you click the button 3 it re-posts your hidden data fields with the
value 3

2) Persist your post data using session variables

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to