Thanks, I should have looked there. However you pointed me in the right direction, and I found the bug I was looking for:
The code to replace in step 7 should be (change bolded, color):
Code:
$pagenav = construct_page_nav($totalmessages, "private.php?$session[sessionurl]folderid=$folderid&pp=$perpage&sort=$sortfield&sortorder=$sortorder");
And one simple improvement in step 12 (change bolded, color), allows you to click the sort on any page #, and maintain the page #:
Code:
<tr>
<td class="thead" nowrap="nowrap"></td>
<if condition="$show['pmicons']">
<td class="thead" nowrap="nowrap"></td>
</if>
<td class="thead" nowrap="nowrap"><a href="$sorturl&order=DESC&sort=dateline&pp=$perpage&folderid=$folderid&page=$pagenumber">Date</a> $sortarrow[dateline]</td>
<td class="thead" nowrap="nowrap"><a href="$sorturl&order=ASC&sort=fromusername&pp=$perpage&folderid=$folderid&page=$pagenumber"><if condition="$folderid==-1">To<else />From</if></a> $sortarrow[fromusername]</td>
<td class="thead" nowrap="nowrap"><a href="$sorturl&order=ASC&sort=title&pp=$perpage&folderid=$folderid&page=$pagenumber">Subject</a> $sortarrow[title]</td>
<td class="thead" nowrap="nowrap" style="padding:0px; border-bottom:1px outset" align="center"><input type="checkbox" id="checkall_$groupid" title="$vbphrase[select_deselect_all_in_time_period]" onclick="check_all_group(this, '$groupid')" /></td>
</tr>
After thos fixes, as far as I can tell, the mod is now working perfectly. Thanks for the mod, Mark, it's a huge improvement for alot of my users.