Advertisement:

Author Topic: No pagination on ad management page in user area [SOLVED]  (Read 2024 times)

goodidea

  • Newbie
  • *
  • Posts: 25
No pagination on ad management page in user area [SOLVED]
« on: May 02, 2015, 11:58:25 am »
Hi,

I can see pagination code on "user-items.php" of twitter theme but there is no pagination on ad management page. I have 17 test ads in my account but after logging into account when I click on ad management tab in user area it shows last 10 ads without pagination. With this user will not be able to edit/delete his old ads. It is very serious issue for my project. Please help me resolve it. A screen shot is attached

Thanks,
« Last Edit: May 03, 2015, 09:43:34 am by goodidea »

teseo

  • Hero Member
  • *****
  • Posts: 6169
Re: No pagination on ad management page in user area
« Reply #1 on: May 03, 2015, 01:36:38 am »
Hi,

Are you using Twitter with latest Osclass? ??? This theme is discontinued ("Compatible up to: 3.4.1"). This deprecated function is the responsible for the issue:

Code: [Select]
    // DEPRECATED: This function will be removed in version 4.0
    function osc_list_total_pages() {
        return osc_search_total_pages();
    }

Anyway, to solve this you need to look for these lines on twitter/functions.php:

Code: [Select]
    function twitter_user_item_pagination() {
        $params = array( 'total'              => (int) View::newInstance()->_get('list_total_pages'),
                        'selected'           => (int) View::newInstance()->_get('list_page'),

and replace them with:

Code: [Select]
    function twitter_user_item_pagination() {
        $params = array( 'total'    => osc_search_total_pages(),
                        'selected' => osc_search_page(),

Regards

goodidea

  • Newbie
  • *
  • Posts: 25
Re: No pagination on ad management page in user area
« Reply #2 on: May 03, 2015, 09:43:06 am »
 Yes teseo I am using twitter theme with latest osclass. But your solution worked very well, thanks  :)
« Last Edit: May 03, 2015, 09:46:42 am by goodidea »

teseo

  • Hero Member
  • *****
  • Posts: 6169
Re: No pagination on ad management page in user area [SOLVED]
« Reply #3 on: May 03, 2015, 02:18:10 pm »
You're welcome. :) The problem is that you'll likely keep finding more of this kind of incompatibilities... :(

Regards