Jump to content

Problems with sending values from one form to another page


radiations3

Recommended Posts

HI,

I am trying to use pagination on the record getting displayed into the table and there's restriction on record that at a time total 15 records can be displayed and others will be displayed by clicking on NEXT (on which i did the following coding).

In my SQL query 'where' clause there is

select * from db where status = $query

 

<?php if ($pageNum_Recordset1 < $totalPages_Recordset1) { // Show if not last page ?>
            <a href="<?php printf("%s?pageNum_Recordset1=%d%s", $currentPage, min($totalPages_Recordset1, $pageNum_Recordset1 + 1), $queryString_Recordset1); ?>?id=<?php echo $yes;?>">Next</a>
            <?php   } // Show if not last page ?>

 

The problem that i am facing is when i click on next then the $query gets equal to null which results to showing no record into the table

kindly help how can i modify the above code so the previous value present in $query doesn't get NULL by clicking on next and show next 15 records sucessfully???

NOTE: The main purpose of the above mentioned code is to show next 15 records (which works fine if $query != NULL).

SOLVED IT MYSELF

<?php if ($pageNum_Recordset1 < $totalPages_Recordset1) { // Show if not last page ?>
            <a href="<?php printf("%s?pageNum_Recordset1=%d%s&id=$yes", $currentPage, min($totalPages_Recordset1, $pageNum_Recordset1 + 1), $queryString_Recordset1) ?>">Next</a>
            <?php   } // Show if not last page ?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.