php forum
php mysql forum
php mysql smarty
 
Topic Options
#285642 - 06/24/05 08:54 AM Finished-[6.5] Paginate PMs 1.0
Anno Offline
Code Monkey

Registered: 05/23/01
Posts: 562
Loc: Austria

   Finished-[6.5] Paginate PMs 1.0 to Del.icio.us Add to del.icio.us
  Digg Finished-[6.5] Paginate PMs 1.0 Digg it
Mod Name / Version: Paginate PMs 1.0 <br /> <br />Description: Splits the list of PMs into pages. The number of PMs per page is twice the number of posts per page on postlist.php. <br /> <br />Working Under: UBB.Threads 6.5, likely also 6.4x, 6.5.1, 6.5.1.1 and 6.5.2 <br /> <br />Mod Status: Finished <br /> <br />Any pre-requisites: none <br /> <br />Author(s): Anno <br /> <br />Date: 06/24/05 <br /> <br />Credits: <br /> <br />Files Altered: <br />viewmessages.php <br />templates/default/viewmessages.tmpl <br /> <br />New Files: none <br /> <br />Database Altered: no <br /> <br />Info/Instructions: In attachment <br /> <br />Disclaimer: Please backup every file that you intend to modify. <br /> <br />Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you might need to restore unmodified files.


Attachments
128450-paginate_PMs_6.5_1.0.txt (86 downloads)



Edited by Anno (06/25/05 02:22 PM)

Top
#285643 - 06/25/05 08:05 AM Re: Beta-[6.5] Paginate PMs [Re: domain123]
Anno Offline
Code Monkey

Registered: 05/23/01
Posts: 562
Loc: Austria
Fixed a bug which resulted in an infinite loop when all messages were deleted.<br /><br />If you already applied the mod, please reaply this step:<br /><br />in viewmessages.php<br /><br />Old code:<br />
Code:
  <br />#### Search for:<br />$i = 0;<br /><br />#### Insert before:<br />	$numpms = $dbh-&gt;total_rows($sth);<br />	<br />	if ($numpms == 0 &amp;&amp; $page &gt; 0){<br />		$page = ceil($nums/$PostsPer)-1;<br />	}	<br />}while ($numpms == 0);<br />.........<br />.........<br />.........<br />
<br /><br />New code:<br />
Code:
 <br />	$numpms = $dbh-&gt;total_rows($sth);<br />	$reloop = 0;<br />	if ($numpms == 0 &amp;&amp; $page &gt; 0){<br />		$page = ceil($nums/$PostsPer)-1;<br />		$reloop = 1; <br />	}	<br />}while ($reloop == 1);<br />.........<br />.........<br />.........<br /> 
<br /><br />I uploaded the new version in the attachemnt of the first post.

Top
#285644 - 06/25/05 09:34 AM Re: Beta-[6.5] Paginate PMs [Re: domain123]
bostongio Offline
Lurker

Registered: 09/30/04
Posts: 8
Hmm, this looks familiar...

Top
#285645 - 06/25/05 10:31 AM Re: Beta-[6.5] Paginate PMs [Re: lexa1999]
Anno Offline
Code Monkey

Registered: 05/23/01
Posts: 562
Loc: Austria
Indeed it should

Top
#285646 - 07/25/05 03:26 AM Re: Beta-[6.5] Paginate PMs [Re: domain123]
Jest Offline
Lurker

Registered: 02/23/05
Posts: 7
Cool... it works fine...
_________________________
br
Thomas
www.mobile.si

Top


Moderator:  Ian_W 
Top Posters Last 30 Days
AllenAyres 12
Gizmo 10
S7ARBVCK 2
Cambridge 1
Murphdog 1
MattUK 1
Kevin H 1
Who's Online
0 Registered (), 39 Guests and 9 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
BeyondCompare v3.00
by blaaskaak
09/05/08 02:46 PM
Noob - need help, or a reality check!
by Gizmo
09/04/08 03:21 AM
Here I am! Rock me like a Hurricane!
by AllenAyres
09/02/08 03:05 PM
[7.x] Generic Page Outside of forum directory
by Gizmo
08/30/08 05:43 PM
Team UBBDev Rides Again!
by Gizmo
08/28/08 11:45 PM
Multiple Identity Detector
by MattUK
08/28/08 04:10 PM
[7.3.x] ubb.links
by AllenAyres
08/26/08 09:57 AM
New Mods
Installing FlashChat with 7.3
by Paug
08/23/08 12:14 AM
[7.3.x] ubb.links
by AllenAyres
06/20/08 11:50 PM
[7.2.1] - Naked shoutbox
by sirdude
08/17/07 10:36 PM
[7.x] Generic Page Outside of forum directory
by
01/14/07 10:58 PM
Multiple Identity Detector
by
12/30/06 06:39 PM
Newest Members
veedubb8, twentyseven, Claus1, welcomeback1, Paug
13327 Registered Users

 

 

 
fusionbb message board php hacks