Changeset 749157
- Timestamp:
- 08/01/2013 09:14:09 AM (13 years ago)
- File:
-
- 1 edited
-
paginate/trunk/readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
paginate/trunk/readme.txt
r749111 r749157 43 43 *Install and Activate* 44 44 45 1. Download and unzip 'paginate.zip'.46 2. Upload the 'paginate' directory to the '/wp-content/plugins/'directory.47 3. Activate the plugin through the 'Plugins'menu in WordPress.45 1. Download and unzip `paginate.zip`. 46 2. Upload the 'paginate' directory to the `/wp-content/plugins/` directory. 47 3. Activate the plugin through the `Plugins` menu in WordPress. 48 48 4. In your theme, modify the CSS file to change the look and feel of your pagination. 49 49 … … 51 51 52 52 3 line implementation 53 <?php 53 54 `<?php 54 55 $totalitems = $wpdb->get_var("SELECT COUNT(ID) FROM $wpdb->users"); 55 56 $p = new paginate($totalitems); 56 57 echo $p->get_pagination(); 57 ?> 58 ?>` 58 59 59 60 60 61 Post onpage argument 61 <?php 62 63 `<?php 62 64 $onPage = $_GET['page'] 63 65 $totalitems = $wpdb->get_var("SELECT COUNT(ID) FROM $wpdb->users"); 64 66 $p = new paginate($totalitems); 65 67 echo $p->get_pagination($onPage); 66 ?> 68 ?>` 67 69 68 70 69 71 Example implementation 70 <?php 72 73 `<?php 71 74 //get total items from database 72 75 $totalitems = $wpdb->get_var("SELECT COUNT(ID) FROM $wpdb->users"); … … 86 89 //pagination html 87 90 echo $p->get_pagination(); 88 ?> 91 ?>`
Note: See TracChangeset
for help on using the changeset viewer.