Parse and pagination script
Posted: Fri May 11, 2007 12:05 pm
Hello everyone,
I am sorry for asking such a simple question but I am desperate to find the answer as I am still a novice in PHP and I need this to be done. I used search but still it did not help me solve my problem.
So, here is the code
I need to add pagination above and below the results, which can be adjusted by a variable in the code. Please help me with that, I will be very grateful, I hope I will be able to learn from that! Thank you very much in advance!
I am sorry for asking such a simple question but I am desperate to find the answer as I am still a novice in PHP and I need this to be done. I used search but still it did not help me solve my problem.
So, here is the code
Code: Select all
<?
$base=file("x.txt");
for($i=0;$i<sizeof($base);$i++){
$base[$i]=rtrim($base[$i]);
$base[$i]=explode("\t",$base[$i]);
}
echo "<table>";
for($i=0;$i<sizeof($base);$i++){
echo "<tr>";
for($j=0;$j<sizeof($base[$i]);$j++){
echo "<td><font size=1 face=tahoma>".$base[$i][$j]."</td>";
}
echo "</tr>";
}
echo "</table>";
?>