No pagination for stories in profile

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 08-07-2006, 02:22 AM
Pligg Developer/Admin
Pligg Version: 0
Pligg Template: none
 
Join Date: Jun 2006
Location: Muncie, Indiana
Posts: 3,215
If you view someone's profile and lets say, for example, you want to view their published stories so you click on the published stories link in their profile. The problem is that it only shows one page (8 stories in my case) of stories even though the user might have 30 stories published. I have added "previous" and "next" page buttons so no matter what link you click on in someone's profile, be it published stories, sent stories, etc etc, you will be able to see all the stories in that particular category instead of only one page.

I'm gonna try my best to remember how I added the pagination. In your user_center.tpl replace this php switch statement
PHP Code:
{php}
Global 
$db$main_smarty$view$user$rows$page_size$offset;

switch (
$view) {
    case 
'history':
        
do_history();    
        break;
    case 
'published':
        
do_published();
        break;
    case 
'shaken':
        
do_shaken();
        break;
    case 
'profile':
        default:
        break;
    
    case 
'removefriend':
        
do_removefriend();
        break;
    case 
'addfriend':
        
do_addfriend();
        break;

    case 
'viewfriends':
        
do_viewfriends();
        break;

    case 
'viewfriends2':
        
do_viewfriends2();
        break;

    case 
'sendmessage':
        
do_sendmessage();
        break;
}    



{/
php
with

PHP Code:
{php}
Global 
$db$main_smarty$view$user$rows$page_size$offset;

switch (
$view) {
    case 
'history':
        
do_history();
        
do_pages($rows$page_size);        
        break;
    case 
'published':
        
do_published();
        
do_pages($rows$page_size); 
        break;
    case 
'shaken':
        
do_shaken();
        
do_pages($rows$page_size);
        break;
    case 
'profile':
        default:
        break;
    
    case 
'removefriend':
        
do_removefriend();
        break;
    case 
'addfriend':
        
do_addfriend();
        break;

    case 
'viewfriends':
        
do_viewfriends();
        break;

    case 
'viewfriends2':
        
do_viewfriends2();
        break;

    case 
'sendmessage':
        
do_sendmessage();
        break;
}    



{/
php
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Fixes to Profile Extra Fields Module v0.2 and Extended Profile Module v0.1 redwine Questions and Comments 11 12-20-2010 04:18 PM
Where is the profile page located? oobie11 Questions and Comments 0 06-18-2009 04:58 AM
Tabbed Menu and Profile!!! Just about done... Genghis Questions and Comments 1 05-11-2007 04:43 AM
How can I add new fields to user profile gragland Questions and Comments 0 07-18-2006 01:03 AM
[bug fix] add pagination to user profile gragland Questions and Comments 3 07-08-2006 10:33 AM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development