Log in

View Full Version : How do I make it force to show all PMs?


Gutspiller
04-09-2002, 05:11 AM
Here is my code from my priv_dateselect template:



<table cellspacing="0" cellpadding="0" border="0">
<form action="private$privpage.php" method="post">
<tr>
<td><input type="hidden" name="s" value="$session[sessionhash]"><input type="hidden" name="$folderid" value="$folderid">
<smallfont><b>Show Messages From:</b>
<nobr><select name="daysprune" onchange="window.location=('private$privpage.php?s=$session[sessionhash]&folderid=$folderid&daysprune=' + this.options[this.selectedIndex].value)">
<!-- <option value="1" $daysprunesel[1]>last day</option>
<option value="2" $daysprunesel[2]>last 2 days</option>
<option value="5" $daysprunesel[5]>last 5 days</option>
<option value="10" $daysprunesel[10]>last 10 days</option>
<option value="20" $daysprunesel[20]>last 20 days</option>
<option value="30" $daysprunesel[30]>last 30 days</option>
<option value="45" $daysprunesel[45]>last 45 days</option>
<option value="60" $daysprunesel[60]>last 60 days</option>
<option value="75" $daysprunesel[75]>last 75 days</option>
<option value="100" $daysprunesel[100]>last 100 days</option>
<option value="365" $daysprunesel[365]>the last year</option> -->
<option value="1000" $daysprunesel[1000]>the beginning</option>
</select> <input type="image" src="{imagesfolder}/go.gif" border="0" align="absbottom"></nobr></smallfont></td>
</tr>
</form>
</table>



I remarked out all the options except the 1000, is all that does is show that as the only option, but it doesn't work until you click go then it will show all, and if you refresh the page it goes back to normal. How to I force the system to show all PMs with no other settings?

I am close, but I don't know what I am doing wrong?

Any help would be great.

Thanks!

Admin
04-09-2002, 11:11 AM
In private.php replace this:
// generate days prune sql condition
if (!$daysprune) {
if ($bbuserinfo[daysprune] == -1) {
$daysprune = "all";
} else {
$daysprune = $bbuserinfo[daysprune];
}
}
with this:
// generate days prune sql condition
if (!$daysprune) {
$daysprune = 'all';
}
Or just remove the if statement and leave the middle line, but then your users won't be able to change the daysprune.

Gutspiller
04-09-2002, 07:55 PM
ALL HAIL FIREFLY!

https://vborg.vbsupport.ru/external/2003/03/7.gif

:D

Thanks.

Admin
04-10-2002, 09:57 AM
No problems Guts. :)