1) Script Title: Ajax Pagination script v1.2.2
2) Script URL (on DD): Ajax Pagination script v1.2.2
3) Describe problem:
I'm trying the MySql Method, the page only has numbers with the word next
The MySql used:
Have I missed something in the code? are the ID's wrong? the URL wrong?PHP Code:<div id="paginate-top"> </div>
<div id="bookdiv"> </div>
<div id="paginate-bottom"> </div>
<script type="text/javascript">
<?php
echo "var commentsbook={\n"; //Dynamically output javascript variable
$commentids=mysql_query("select * from tblprojects"); //get IDs to last 5 comment pages
$idarray=array();
while ($theid=mysql_fetch_array($commentids)){
array_push($idarray, "'demo.php?id=" . $theid[serviceid] . "'");
}
echo "pages: [" . implode(",", $idarray) . "],\n"; //output: pages: [filepath1, filepath2, filepath3, etc],
echo "selectedpage: 2\n}";
?>
var comments=new ajaxpageclass.createBook(commentsbook, "bookdiv", ["paginate-top", "paginate-bottom"])
</script>
How exactly does the data get displayed when there isn't any?
I know ofjah(url,target) {the data that needs to be loaded is in the database not apage.html
Solved!
Code:<script type="text/javascript" src="js/jah.js"></script> <script type="text/javascript" > window.onload=function(){ jah('prolist.php?pageNum_rsprojects=0','prolist'); } </script>



Reply With Quote
Bookmarks