Login   Register  
PHP Classes
elePHPant
Icontem

File: home

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of pugazhenthi  >  pagenation  >  home  >  Download  
File: home
Role: Example script
Content type: text/plain
Description: calling pagenation
Class: pagenation
Split MySQL query results into pages
Author: By
Last change:
Date: 4 years ago
Size: 865 bytes
 

Contents

Class file image Download
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>
<?php
    
include('splitMain.php');
    
$conn=mysql_connect('localhost','root','');
    
mysql_select_db('php_db',$conn);
    
$query="SELECT * FROM new_table";
    
$obj = new pageMain($conn,$query,4);
    
$res $obj->splitTable();
    print(
"<table border=1><tr><td width=25>UserName</a></td><td>PassWord</td></tr>");    
    while(
$row mysql_fetch_array($res))
          {
        print(
"<tr><td width=25>");    
          print(
$row['userName']);
        print(
"</td><td>");
        
print_r($row['passWord']);
        print(
"</td></tr>");
        }
        print(
"</table>");
    print(
$obj->Link());
?>
</body>
</html>