[prev in list] [next in list] [prev in thread] [next in thread] 

List:       phorum-dev
Subject:    [phorum-dev] new threads
From:       "Knud Franzkowiak" <knud.franzkowiak () public-affairs ! net>
Date:       2000-07-25 11:35:05
[Download RAW message or body]

Hi,

in case nobody has mentioned this before (I'm new to this list and
just try to implement Phorum to our demeter.de website):
When you're on the list page you always can push the button 'Newer
messages', although there might be no newer messages anymore.
To avoid this button you easily could do the following in the
list.php file:

Replace this code (line 108):
  else{
    if($action==1){
      $cutoff_thread=$thread+$cutoff;

through that code:
  else {
    if($action==1) {
      $cutoff_thread=$thread+$cutoff;

      $sSQL = "Select max(thread) as thread from $ForumTableName where approved='Y'";
      $q=new query($DB, $sSQL);
      $rec=$q->getrow();
      $maxthread = $rec["thread"];

You'll always get the last thread number to check later if you al-
ready have this thread in your list as the first one:

Replace this code (line 209):
  $pagenav="";
  if($action!=0) ...

through that code:
  $pagenav="";
  if($action!=0 && $maxthread != ($thread - 1)) ...

I think this is much smarter and shows only what is really needed
and can be a functional function after all.

Greetings,
Knud Franzkowiak

--
Knud Franzkowiak                         Dr. Borzner public affairs
Projektleiter Neue Medien       Kiefernweg 5 - D-35096 Niederweimar
Fon: +49 6421 972653                  http://www.public-affairs.net

---------------------------------------------------------------------
To unsubscribe, e-mail: phorum-dev-unsubscribe@lists.phorum.org
For additional commands, e-mail: phorum-dev-help@lists.phorum.org

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic