Forum Moderators: coopster
As anyone done any work with pagination where the input data is an XML document?
Basically I have a PHP page that reads in an XML document. I would like to break up it up so that it only displays 25 results per page. The code snippet below shows what I've done so far. Unfortunately, nothing is being printed out. Any help would be greatly appreciated.
Cheers
Sanjay
//load XML from URL
$xml = simplexml_load_file("https://example.com/rampart/live/getgroups.php?user=$user");
foreach ($xml->xpath("//ns:displayName") as $id){
for($x=($currentpage*25);$x<(($currentpage*25)+25);$x++){
print_r($id($x));
}
}
[edited by: eelixduppy at 12:43 pm (utc) on June 27, 2008]
[edit reason] example.com [/edit]