[cBB Blockgets 1.0.3] Topic index block - pagination problem


no_avatar
leschek
 
Posts: 65
Joined: Sat Sep 08, 2012 10:08 pm
 Tue Nov 27, 2012 11:48 am • via Web
I just would like to say that I really like the new Topic Index block, but it seems there is problem with pagination. If you put the block on viewforum.php page it shows pagination outside the block - above and below the topic list.

Also, would be possible to add column with last post poster ?
User avatar
IvanPF
Administrator
 
Posts: 2028
Joined: Fri Jun 17, 2011 12:15 am
Location: España (Spain)
 Tue Nov 27, 2012 12:00 pm • via Web
Thanks for the report, I will check this as soon as possible
User avatar
IvanPF
Administrator
 
Posts: 2028
Joined: Fri Jun 17, 2011 12:15 am
Location: España (Spain)
 Tue Nov 27, 2012 12:24 pm • via Web
I just would like to say that I really like the new Topic Index block, but it seems there is problem with pagination. If you put the block on viewforum.php page it shows pagination outside the block - above and below the topic list.

Open blockgets/block/topic_index_block.php
Find:
Code: Select all
$start      = request_var('start', 0);


Replace with:
Code: Select all
$start      = ($method == 'pagination') ? request_var('start', 0) : 0;

Find:
Code: Select all
         'PAGINATION'      => ($data['topics_per_page']) ? generate_pagination('#', $topic_count, $data['topics_per_page'], $start) : '',
         'PAGE_NUMBER'      => on_page($topic_count, $data['topics_per_page'], $start),

Replace with:
Code: Select all
         'BLOCK_PAGINATION'      => ($data['topics_per_page']) ? generate_pagination('#', $topic_count, $data['topics_per_page'], $start) : '',
         'BLOCK_PAGE_NUMBER'      => on_page($topic_count, $data['topics_per_page'], $start),


Open styles/{your style}/template/blockgets/block/topic_index_block.html
Find:
Code: Select all
<!-- IF PAGINATION -->
   <div class="pagination">
      <!-- IF not S_SHORT_MODE -->{PAGE_NUMBER} &bull; <!-- ENDIF --><span>{PAGINATION}</span>
   </div>
   <div class="clear"></div>
<!-- ENDIF -->

Replace with:
Code: Select all
<!-- IF BLOCK_PAGINATION -->
   <div class="pagination">
      <!-- IF not S_SHORT_MODE -->{BLOCK_PAGE_NUMBER} &bull; <!-- ENDIF --><span>{BLOCK_PAGINATION}</span>
   </div>
   <div class="clear"></div>
<!-- ENDIF -->
no_avatar
leschek
 
Posts: 65
Joined: Sat Sep 08, 2012 10:08 pm
 Tue Nov 27, 2012 12:45 pm • via Web
Thank you for very fast help. It's working now.
no_avatar
leschek
 
Posts: 65
Joined: Sat Sep 08, 2012 10:08 pm
 Fri Dec 28, 2012 4:42 pm • via Web
It seems there is another problem with this block and pagination. When you have this block on viewtopic/viewforum page and it has more pages, then when you go to page 2,3,4 etc. it will change also page with topics block.
Here is viewtopic example and here viewforum example.
User avatar
IvanPF
Administrator
 
Posts: 2028
Joined: Fri Jun 17, 2011 12:15 am
Location: España (Spain)
 Sun Dec 30, 2012 1:05 pm • via Web
It seems there is another problem with this block and pagination. When you have this block on viewtopic/viewforum page and it has more pages, then when you go to page 2,3,4 etc. it will change also page with topics block.
Here is viewtopic example and here viewforum example.

Have you make this change?
Find:
Code: Select all
$start      = request_var('start', 0);


Replace with:
Code: Select all
$start      = ($method == 'pagination') ? request_var('start', 0) : 0;
no_avatar
leschek
 
Posts: 65
Joined: Sat Sep 08, 2012 10:08 pm
 Mon Dec 31, 2012 6:30 pm • via Web
Thank you.
It's very embarrassing, but it seems I missed those edits when I edited the file first time. I'm really sorry for wasting your time.
User avatar
IvanPF
Administrator
 
Posts: 2028
Joined: Fri Jun 17, 2011 12:15 am
Location: España (Spain)
 Mon Dec 31, 2012 7:33 pm • via Android
Don't worry.

Who is online

Users browsing this forum: No registered users and 0 guests