News Page Number (want the new codezwiz version please)

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   News Page Number (want the new codezwiz version please)
prekill
CZ Newbie
prekill has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Jul 15, 2005
0.00 posts per day
Posts: 28
Points: 148
   
Hey,

The new news page number here: [ Register or login to view links on this board. ]

Is just great!! (Forum too). I was wondering on how to implement this in my phpnuke too. Anyone can give a download link, guide or explanation on how to display it like that?

Thank you!



Back to top Reply with quote
#2   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,430
   
Its a function I made to emulate the IPB page numbers. I will post it up this weekend for you but it will require a little work on your part to implement it. icon_smile.gif




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#3   re: News Page Number (want the new codezwiz version please)
prekill
CZ Newbie
prekill has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Jul 15, 2005
0.00 posts per day
Posts: 28
Points: 148
   
Great!! Thanks, looking foward to it!

As I understand it has something to do with css in my theme too.

icon_wink.gif



Back to top Reply with quote
#4   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,430
   
Have fun... icon_smile.gif
[ Register or login to view links on this board. ]




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#5   re: News Page Number (want the new codezwiz version please)
prekill
CZ Newbie
prekill has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Jul 15, 2005
0.00 posts per day
Posts: 28
Points: 148
   
Thanks! going to try it right now!

Edit: all I am getting is: "Nothing here check back later...". It just seem too hard for be to figer it out. can you provide deeper explanating? please.

(may be show how to do it in news).

Thanks!



Back to top Reply with quote
#6   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,430
   
Attach your News/index.php and the one you edited.




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#7   re: News Page Number (want the new codezwiz version please)
prekill
CZ Newbie
prekill has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Jul 15, 2005
0.00 posts per day
Posts: 28
Points: 148
   
Hey,

This is my original news index.php:
<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2002 by Francisco Burzi                                */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/
/*         Additional security & Abstraction layer conversion           */
/*                           2003 chatserv                              */
/*      http://www.nukefixes.com -- http://www.nukeresources.com        */
/************************************************************************/

if (!stristr($_SERVER['SCRIPT_NAME'], "modules.php")) {
    die ("You can't access this file directly...");
}

$index = 1;
require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);

function theindex($new_topic=0) {
    global $pagenum, $db, $storyhome, $topicname, $topicimage, $topictext, $datetime, $user, $cookie, $nukeurl, $prefix, $multilingual, $currentlang, $articlecomm, $sitename, $user_news;
    if ($multilingual == 1) {
   $querylang = "AND (alanguage='$currentlang' OR alanguage='')";
    } else {
   $querylang = "";
    }
    include("header.php");
    automated_news();
    if (isset($new_topic)) {
    $new_topic = intval($new_topic);
    } else {
    $new_topic == 0;
    }
    if (isset($cookie[3]) AND $user_news == 1) {
   $storynum = $cookie[3];
    } else {
   $storynum = $storyhome;
    }
    if ($new_topic == 0) {
   $qdb = "WHERE (ihome='0' OR catid='0')";
   $home_msg = "";
    } else {
   $qdb = "WHERE topic='$new_topic'";
   $result_a = $db->sql_query("SELECT topictext FROM ".$prefix."_topics WHERE topicid='$new_topic'");
   $row_a = $db->sql_fetchrow($result_a);   
   $numrows_a = $db->sql_numrows($result_a);
   $topic_title = stripslashes(check_html($row_a['topictext'], "nohtml"));
   OpenTable();
   if ($numrows_a == 0) {
       echo "<center><font class=\"title\">$sitename</font><br><br>"._NOINFO4TOPIC."<br><br>[ <a href=\"modules.php?name=News\">"._GOTONEWSINDEX."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
   } else {
       echo "<center><font class=\"title\">$sitename: $topic_title</font><br><br>"
      ."<form action=\"modules.php?name=Search\" method=\"post\">"
      ."<input type=\"hidden\" name=\"topic\" value=\"$new_topic\">"
      .""._SEARCHONTOPIC.": <input type=\"name\" name=\"query\" size=\"30\">&nbsp;&nbsp;"
      ."<input type=\"submit\" value=\""._SEARCH."\">"
      ."</form>"
      ."[ <a href=\"index.php\">"._GOTOHOME."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
   }
   CloseTable();
   echo "<br>";
    }
   if ($pagenum == "") { $pagenum = 1 ; }
    $offset = ($pagenum-1) * $storynum ;
    $result = $db->sql_query("SELECT sid, catid, aid, title, time, hometext, bodytext, comments, counter, topic, informant, notes, acomm, score, ratings FROM ".$prefix."_stories $qdb $querylang ORDER BY sid DESC limit $offset, $storynum");
    while ($row = $db->sql_fetchrow($result)) {
   $s_sid = intval($row['sid']);
   $catid = intval($row['catid']);
    $aid = stripslashes($row['aid']);
    $title = stripslashes(check_html($row['title'], "nohtml"));
    $time = $row['time'];
    $hometext = stripslashes($row['hometext']);
    $bodytext = stripslashes($row['bodytext']);
    $comments = stripslashes($row['comments']);
    $counter = intval($row['counter']);
    $topic = intval($row['topic']);
    $informant = stripslashes($row['informant']);
    $notes = stripslashes($row['notes']);
   $acomm = intval($row['acomm']);
   $score = intval($row['score']);
   $ratings = intval($row['ratings']);
   if ($catid > 0) {
       $row2 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
       $cattitle = stripslashes(check_html($row2['title'], "nohtml"));
   }
   getTopics($s_sid);
   formatTimestamp($time);
   $subject = stripslashes(check_html($subject, "nohtml"));
   $introcount = strlen($hometext);
   $fullcount = strlen($bodytext);
   $totalcount = $introcount + $fullcount;
   $c_count = $comments;
   $r_options = "";
      if (isset($cookie[4])) { $r_options .= "&amp;mode=$cookie[4]"; }
      if (isset($cookie[5])) { $r_options .= "&amp;order=$cookie[5]"; }
      if (isset($cookie[6])) { $r_options .= "&amp;thold=$cookie[6]"; }
   $story_link = "<a href=\"modules.php?name=News&file=article&sid=$s_sid$r_options\">";
   $morelink = "(";
   if ($fullcount > 0 OR $c_count > 0 OR $articlecomm == 0 OR $acomm == 1) {
       $morelink .= "$story_link<b>"._READMORE."</b></a> | ";
   } else {
       $morelink .= "";
   }
   if ($fullcount > 0) { $morelink .= "$totalcount "._BYTESMORE." | "; }
   if ($articlecomm == 1 AND $acomm == 0) {
       if ($c_count == 0) { $morelink .= "$story_link"._COMMENTSQ."</a>"; } elseif ($c_count == 1) { $morelink .= "$story_link$c_count "._COMMENT."</a>"; } elseif ($c_count > 1) { $morelink .= "$story_link$c_count "._COMMENTS."</a>"; }
   }
   $sid = intval($s_sid);
   if ($catid != 0) {
       $row3 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
       $title1 = stripslashes(check_html($row3['title'], "nohtml"));
       $title = "<a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\"><font class=\"storycat\">$title1</font></a>: $title";
       $morelink .= " | <a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\">$title1</a>";
   }
   if ($score != 0) {
       $rated = substr($score / $ratings, 0, 4);
   } else {
       $rated = 0;
   }
   $morelink .= " | "._SCORE." $rated";
   $morelink .= ")";
   $morelink = str_replace(" |  | ", " | ", $morelink);
   themeindex($aid, $informant, $datetime, $title, $counter, $topic, $hometext, $notes, $morelink, $topicname, $topicimage, $topictext);
    }
    #START Page Numbers
   #$limitpn = "limit 100"; # limit number of stories
   $sql_pn = "select * from ".$prefix."_stories $qdb $querylang $limitpn";
   $result_pn = $db->sql_query($sql_pn);
   $numstories = $db->sql_numrows($result_pn);
   $numpages = ceil($numstories / $storynum);
   #if ($numpages > 1 and $new_topic == 0) {
   if ($numpages > 1) {
      opentable();
      echo "<center>$numstories "._STORIES." ($numpages "._PAGES.", $storynum "._PERPAGE.")<br>" ;
      if ($pagenum > 1) {
         $prevpage = $pagenum - 1 ;
         $leftarrow = "images/left.gif" ;
         if(isset($new_topic)) {
            echo "<a href=\"modules.php?name=News&new_topic=$new_topic&pagenum=$prevpage\">";
            echo "<img src=\"$leftarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã ä÷åãí\"></a>";
         } else {
            echo "<a href=\"modules.php?name=News&pagenum=$prevpage\">";
            echo "<img src=\"$leftarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã ä÷åãí\"></a>";
         }
      }
      echo "[ " ;
      for ($i=1; $i < $numpages+1; $i++) {
         if ($i == $pagenum) {
            echo "<b>$i</b>";
         } else {
            if(isset($new_topic)) {
               echo "<a href=\"modules.php?name=News&new_topic=$new_topic&pagenum=$i\">$i</a>";
            } else {
               echo "<a href=\"modules.php?name=News&pagenum=$i\">$i</a>";
            }
         }
         if ($i < $numpages) { echo " | "; } else { echo " ]"; }
      }
      if ($pagenum < $numpages) {
         $nextpage = $pagenum + 1 ;
         $rightarrow = "images/right.gif" ;
         if(isset($new_topic)) {
            echo "<a href=\"modules.php?name=News&new_topic=$new_topic&pagenum=$nextpage\">";
            echo "<img src=\"$rightarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã äáà\"></a>";
         } else {
            echo "<a href=\"modules.php?name=News&pagenum=$nextpage\">";
            echo "<img src=\"$rightarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã äáà\"></a>";
         }
      }
      echo "</center>" ;
      closetable();
   }
   #END Page Numbers
   include("footer.php");
}

function rate_article($sid, $score) {
    global $prefix, $db, $ratecookie, $sitename, $r_options;
    $score = intval($score);
    $sid = intval($sid);
    if ($score) {
   if ($score > 5) { $score = 5; }
   if ($score < 1) { $score = 1; }
   if ($score != 1 AND $score != 2 AND $score != 3 AND $score != 4 AND $score != 5) {
       Header("Location: index.php");
       die();
   }
   if (isset($ratecookie)) {
       $rcookie = base64_decode($ratecookie);
       $rcookie = addslashes($rcookie);
       $r_cookie = explode(":", $rcookie);
   }
   for ($i=0; $i < sizeof($r_cookie); $i++) {
       if ($r_cookie[$i] == $sid) {
      $a = 1;
       }
   }
   if ($a == 1) {
       Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
   } else {
       $result = $db->sql_query("update ".$prefix."_stories set score=score+$score, ratings=ratings+1 where sid='$sid'");
       $info = base64_encode("$rcookie$sid:");
       setcookie("ratecookie","$info",time()+3600);
       Header("Location: modules.php?name=News&op=rate_complete&sid=$sid$r_options");
   }
    } else {
   include("header.php");
   title("$sitename: "._ARTICLERATING."");
   OpenTable();
   echo "<center>"._DIDNTRATE."<br><br>"
       .""._GOBACK."</center>";
   CloseTable();
   include("footer.php");
    }
}

function rate_complete($sid, $rated=0) {
    global $sitename, $user, $cookie;
    $r_options = "";
    if (is_user($user)) {
   if (isset($cookie[4])) { $r_options .= "&amp;mode=$cookie[4]"; }
   if (isset($cookie[5])) { $r_options .= "&amp;order=$cookie[5]"; }
        if (isset($cookie[6])) { $r_options .= "&amp;thold=$cookie[6]"; }
    }
    include("header.php");
    title("$sitename: "._ARTICLERATING."");
    OpenTable();
    if ($rated == 0) {
   echo "<center>"._THANKSVOTEARTICLE."<br><br>"
       ."[ <a href=\"modules.php?name=News&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
    } elseif ($rated == 1) {
   echo "<center>"._ALREADYVOTEDARTICLE."<br><br>"
       ."[ <a href=\"modules.php?name=News&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
    }
    CloseTable();
    include("footer.php");
}

switch ($op) {

    default:
    theindex($new_topic);
    break;

    case "rate_article":
    rate_article($sid, $score);
    break;

    case "rate_complete":
    rate_complete($sid, $rated);
    break;

}

?>


This is the one I edit:
<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2002 by Francisco Burzi                                */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/
/*         Additional security & Abstraction layer conversion           */
/*                           2003 chatserv                              */
/*      http://www.nukefixes.com -- http://www.nukeresources.com        */
/************************************************************************/

if (!stristr($_SERVER['SCRIPT_NAME'], "modules.php")) {
    die ("You can't access this file directly...");
}

$index = 1;
require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);

function theindex($new_topic=0) {
    global $pagenum, $db, $storyhome, $topicname, $topicimage, $topictext, $datetime, $user, $cookie, $nukeurl, $prefix, $multilingual, $currentlang, $articlecomm, $sitename, $user_news;
    if ($multilingual == 1) {
   $querylang = "AND (alanguage='$currentlang' OR alanguage='')";
    } else {
   $querylang = "";
    }
    include("header.php");
    automated_news();
    if (isset($new_topic)) {
    $new_topic = intval($new_topic);
    } else {
    $new_topic == 0;
    }
    if (isset($cookie[3]) AND $user_news == 1) {
   $storynum = $cookie[3];
    } else {
   $storynum = $storyhome;
    }
    if ($new_topic == 0) {
   $qdb = "WHERE (ihome='0' OR catid='0')";
   $home_msg = "";
    } else {
   $qdb = "WHERE topic='$new_topic'";
   $result_a = $db->sql_query("SELECT topictext FROM ".$prefix."_topics WHERE topicid='$new_topic'");
   $row_a = $db->sql_fetchrow($result_a);   
   $numrows_a = $db->sql_numrows($result_a);
   $topic_title = stripslashes(check_html($row_a['topictext'], "nohtml"));
   OpenTable();
   if ($numrows_a == 0) {
       echo "<center><font class=\"title\">$sitename</font><br><br>"._NOINFO4TOPIC."<br><br>[ <a href=\"modules.php?name=News\">"._GOTONEWSINDEX."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
   } else {
       echo "<center><font class=\"title\">$sitename: $topic_title</font><br><br>"
      ."<form action=\"modules.php?name=Search\" method=\"post\">"
      ."<input type=\"hidden\" name=\"topic\" value=\"$new_topic\">"
      .""._SEARCHONTOPIC.": <input type=\"name\" name=\"query\" size=\"30\">&nbsp;&nbsp;"
      ."<input type=\"submit\" value=\""._SEARCH."\">"
      ."</form>"
      ."[ <a href=\"index.php\">"._GOTOHOME."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
   }
   CloseTable();
   echo "<br>";
    }
   if ($pagenum == "") { $pagenum = 1 ; }
    $offset = ($pagenum-1) * $storynum ;
    $result = $db->sql_query("SELECT sid, catid, aid, title, time, hometext, bodytext, comments, counter, topic, informant, notes, acomm, score, ratings FROM ".$prefix."_stories $qdb $querylang ORDER BY sid DESC limit $offset, $storynum");
    while ($row = $db->sql_fetchrow($result)) {
   $s_sid = intval($row['sid']);
   $catid = intval($row['catid']);
    $aid = stripslashes($row['aid']);
    $title = stripslashes(check_html($row['title'], "nohtml"));
    $time = $row['time'];
    $hometext = stripslashes($row['hometext']);
    $bodytext = stripslashes($row['bodytext']);
    $comments = stripslashes($row['comments']);
    $counter = intval($row['counter']);
    $topic = intval($row['topic']);
    $informant = stripslashes($row['informant']);
    $notes = stripslashes($row['notes']);
   $acomm = intval($row['acomm']);
   $score = intval($row['score']);
   $ratings = intval($row['ratings']);
   if ($catid > 0) {
       $row2 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
       $cattitle = stripslashes(check_html($row2['title'], "nohtml"));
   }
   getTopics($s_sid);
   formatTimestamp($time);
   $subject = stripslashes(check_html($subject, "nohtml"));
   $introcount = strlen($hometext);
   $fullcount = strlen($bodytext);
   $totalcount = $introcount + $fullcount;
   $c_count = $comments;
   $r_options = "";
      if (isset($cookie[4])) { $r_options .= "&amp;mode=$cookie[4]"; }
      if (isset($cookie[5])) { $r_options .= "&amp;order=$cookie[5]"; }
      if (isset($cookie[6])) { $r_options .= "&amp;thold=$cookie[6]"; }
   $story_link = "<a href=\"modules.php?name=News&file=article&sid=$s_sid$r_options\">";
   $morelink = "(";
   if ($fullcount > 0 OR $c_count > 0 OR $articlecomm == 0 OR $acomm == 1) {
       $morelink .= "$story_link<b>"._READMORE."</b></a> | ";
   } else {
       $morelink .= "";
   }
   if ($fullcount > 0) { $morelink .= "$totalcount "._BYTESMORE." | "; }
   if ($articlecomm == 1 AND $acomm == 0) {
       if ($c_count == 0) { $morelink .= "$story_link"._COMMENTSQ."</a>"; } elseif ($c_count == 1) { $morelink .= "$story_link$c_count "._COMMENT."</a>"; } elseif ($c_count > 1) { $morelink .= "$story_link$c_count "._COMMENTS."</a>"; }
   }
   $sid = intval($s_sid);
   if ($catid != 0) {
       $row3 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
       $title1 = stripslashes(check_html($row3['title'], "nohtml"));
       $title = "<a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\"><font class=\"storycat\">$title1</font></a>: $title";
       $morelink .= " | <a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\">$title1</a>";
   }
   if ($score != 0) {
       $rated = substr($score / $ratings, 0, 4);
   } else {
       $rated = 0;
   }
   $morelink .= " | "._SCORE." $rated";
   $morelink .= ")";
   $morelink = str_replace(" |  | ", " | ", $morelink);
   themeindex($aid, $informant, $datetime, $title, $counter, $topic, $hometext, $notes, $morelink, $topicname, $topicimage, $topictext);
    }
    #START Page Numbers
   #$limitpn = "limit 100"; # limit number of stories
   $sql_pn = "select * from ".$prefix."_stories $qdb $querylang $limitpn";
   $result_pn = $db->sql_query($sql_pn);
   $numstories = $db->sql_numrows($result_pn);
   $numpages = ceil($numstories / $storynum);
   #if ($numpages > 1 and $new_topic == 0) {
   if ($numpages > 1) {
      opentable();
      echo "<center>$numstories "._STORIES." ($numpages "._PAGES.", $storynum "._PERPAGE.")<br>" ;
      if ($pagenum > 1) {
         $prevpage = $pagenum - 1 ;
         $leftarrow = "images/left.gif" ;
         if(isset($new_topic)) {
            echo "<a href=\"modules.php?name=News&new_topic=$new_topic&pagenum=$prevpage\">";
            echo "<img src=\"$leftarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã ä÷åãí\"></a>";
         } else {
            echo "<a href=\"modules.php?name=News&pagenum=$prevpage\">";
            echo "<img src=\"$leftarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã ä÷åãí\"></a>";
         }
      }
      echo "[ " ;
      for ($i=1; $i < $numpages+1; $i++) {
         if ($i == $pagenum) {
            echo "<b>$i</b>";
         } else {
            if(isset($new_topic)) {
               echo "<a href=\"modules.php?name=News&new_topic=$new_topic&pagenum=$i\">$i</a>";
            } else {
               echo "<a href=\"modules.php?name=News&pagenum=$i\">$i</a>";
            }
         }
         if ($i < $numpages) { echo " | "; } else { echo " ]"; }
      }
      if ($pagenum < $numpages) {
         $nextpage = $pagenum + 1 ;
         $rightarrow = "images/right.gif" ;
         if(isset($new_topic)) {
            echo "<a href=\"modules.php?name=News&new_topic=$new_topic&pagenum=$nextpage\">";
            echo "<img src=\"$rightarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã äáà\"></a>";
         } else {
            echo "<a href=\"modules.php?name=News&pagenum=$nextpage\">";
            echo "<img src=\"$rightarrow\" align=\"middle\" border=\"0\" hspace=\"10\" alt=\"ìòîåã äáà\"></a>";
         }
      }
      echo "</center>" ;
      closetable();
   }
   #END Page Numbers

   #Test New Page Numbers - http://www.codezwiz.com/kbview-55-ipb-like-page-numbers-function.html
    //current page (you should not change this)
    $start = (isset($_POST['start']) ? intval($_POST['start']) : (isset($_GET['start']) ? intval($_GET['start']) : 0));

    //how many per page
    $perpage = '10';

    //this would be an added variable (category)
    $cat = (isset($_POST['cat']) ? intval($_POST['cat']) : (isset($_GET['cat']) ? intval($_GET['cat']) : 0));

//if you where using another variable to call the data you want to add it here also so the page numbers add up
//I added cat as an example if you where using categories for instance.
list($num_pages) = $db->sql_fetchrow($db->sql_query("SELECT COUNT(*) FROM ".$prefix."_stories WHERE cat = '$cat'")); //total pages

//this is where you get the data. Notice we added "LIMIT $start, $perpage" on the end of the query
$result = $db->sql_query("SELECT * FROM ".$prefix."_stories WHERE cat = '$cat' ORDER BY something LIMIT $start, $perpage");
if ($db->sql_numrows($result) > 0) {
   while($row = $db->sql_fetchrow($result)) {
      //your data is here
      $something = $row['something'];
      echo $something;
   }
   $db->sql_freeresult($result);
   //This is the pagination.
   //The first item is the page URL and op if needed. You would also add any other variable you may have to pass to the next page.
   //Next item is total pages
   //Next item is per page
   //Last item is page there on
   $add_url = ($cat > 0) ? '&amp;cat=' . $cat : '';
   echo pagination('modules.php?name=Module&op=Someop' . $add_url, $num_pages, $perpage, $start);
} else {
   echo "Nothing here check back later...";
}
    include('includes/pagination.php');
    #END New Page Numbers
   include("footer.php");
}

function rate_article($sid, $score) {
    global $prefix, $db, $ratecookie, $sitename, $r_options;
    $score = intval($score);
    $sid = intval($sid);
    if ($score) {
   if ($score > 5) { $score = 5; }
   if ($score < 1) { $score = 1; }
   if ($score != 1 AND $score != 2 AND $score != 3 AND $score != 4 AND $score != 5) {
       Header("Location: index.php");
       die();
   }
   if (isset($ratecookie)) {
       $rcookie = base64_decode($ratecookie);
       $rcookie = addslashes($rcookie);
       $r_cookie = explode(":", $rcookie);
   }
   for ($i=0; $i < sizeof($r_cookie); $i++) {
       if ($r_cookie[$i] == $sid) {
      $a = 1;
       }
   }
   if ($a == 1) {
       Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
   } else {
       $result = $db->sql_query("update ".$prefix."_stories set score=score+$score, ratings=ratings+1 where sid='$sid'");
       $info = base64_encode("$rcookie$sid:");
       setcookie("ratecookie","$info",time()+3600);
       Header("Location: modules.php?name=News&op=rate_complete&sid=$sid$r_options");
   }
    } else {
   include("header.php");
   title("$sitename: "._ARTICLERATING."");
   OpenTable();
   echo "<center>"._DIDNTRATE."<br><br>"
       .""._GOBACK."</center>";
   CloseTable();
   include("footer.php");
    }
}

function rate_complete($sid, $rated=0) {
    global $sitename, $user, $cookie;
    $r_options = "";
    if (is_user($user)) {
   if (isset($cookie[4])) { $r_options .= "&amp;mode=$cookie[4]"; }
   if (isset($cookie[5])) { $r_options .= "&amp;order=$cookie[5]"; }
        if (isset($cookie[6])) { $r_options .= "&amp;thold=$cookie[6]"; }
    }
    include("header.php");
    title("$sitename: "._ARTICLERATING."");
    OpenTable();
    if ($rated == 0) {
   echo "<center>"._THANKSVOTEARTICLE."<br><br>"
       ."[ <a href=\"modules.php?name=News&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
    } elseif ($rated == 1) {
   echo "<center>"._ALREADYVOTEDARTICLE."<br><br>"
       ."[ <a href=\"modules.php?name=News&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
    }
    CloseTable();
    include("footer.php");
}

switch ($op) {

    default:
    theindex($new_topic);
    break;

    case "rate_article":
    rate_article($sid, $score);
    break;

    case "rate_complete":
    rate_complete($sid, $rated);
    break;

}

?>


plus I add the css part to my theme style.css and created a new js file named pagination.js in the style folder. (becuase I do not have js file no where.) and put the pagination.php file in the includes folder.

p.s the edit start in : "#Test New Page Numbers"


Back to top Reply with quote
#8   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,430
   
Try this one and let me know how it goes.


<?php

/************************************************************************/
/* PHP-NUKE: Web Portal System                                          */
/* ===========================                                          */
/*                                                                      */
/* Copyright (c) 2002 by Francisco Burzi                                */
/* http://phpnuke.org                                                   */
/*                                                                      */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/
/*         Additional security & Abstraction layer conversion           */
/*                           2003 chatserv                              */
/*      http://www.nukefixes.com -- http://www.nukeresources.com        */
/************************************************************************/

if (!stristr($_SERVER['SCRIPT_NAME'], "modules.php")) {
    die ("You can't access this file directly...");
}

$index = 1;
require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);

#Test New Page Numbers - http://www.codezwiz.com/kbview-55-ipb-like-page-numbers-function.html
include('includes/pagination.php');
#END New Page Numbers

function theindex($new_topic=0) {
    global $pagenum, $db, $storyhome, $topicname, $topicimage, $topictext, $datetime, $user, $cookie, $nukeurl, $prefix, $multilingual, $currentlang, $articlecomm, $sitename, $user_news;
    if ($multilingual == 1) {
   $querylang = "AND (alanguage='$currentlang' OR alanguage='')";
    } else {
   $querylang = "";
    }
    include("header.php");
    automated_news();
    if (isset($new_topic)) {
    $new_topic = intval($new_topic);
    } else {
    $new_topic == 0;
    }
    if (isset($cookie[3]) AND $user_news == 1) {
   $storynum = $cookie[3];
    } else {
   $storynum = $storyhome;
    }
    if ($new_topic == 0) {
   $qdb = "WHERE (ihome='0' OR catid='0')";
   $home_msg = "";
    } else {
   $qdb = "WHERE topic='$new_topic'";
   $result_a = $db->sql_query("SELECT topictext FROM ".$prefix."_topics WHERE topicid='$new_topic'");
   $row_a = $db->sql_fetchrow($result_a);   
   $numrows_a = $db->sql_numrows($result_a);
   $topic_title = stripslashes(check_html($row_a['topictext'], "nohtml"));
   OpenTable();
   if ($numrows_a == 0) {
       echo "<center><font class=\"title\">$sitename</font><br><br>"._NOINFO4TOPIC."<br><br>[ <a href=\"modules.php?name=News\">"._GOTONEWSINDEX."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
   } else {
       echo "<center><font class=\"title\">$sitename: $topic_title</font><br><br>"
      ."<form action=\"modules.php?name=Search\" method=\"post\">"
      ."<input type=\"hidden\" name=\"topic\" value=\"$new_topic\">"
      .""._SEARCHONTOPIC.": <input type=\"name\" name=\"query\" size=\"30\">&nbsp;&nbsp;"
      ."<input type=\"submit\" value=\""._SEARCH."\">"
      ."</form>"
      ."[ <a href=\"index.php\">"._GOTOHOME."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
   }
   CloseTable();
   echo "<br>";
    }
      #Test New Page Numbers - http://www.codezwiz.com/kbview-55-ipb-like-page-numbers-function.html
       $start = (isset($_POST['start']) ? intval($_POST['start']) : (isset($_GET['start']) ? intval($_GET['start']) : 0));
       $perpage = '10';
   list($num_pages) = $db->sql_fetchrow($db->sql_query("SELECT COUNT(*) FROM ".$prefix."_stories $qdb")); //$qdb is an added variable 
       #END New Page Numbers

    $result = $db->sql_query("SELECT sid, catid, aid, title, time, hometext, bodytext, comments, counter, topic, informant, notes, acomm, score, ratings FROM ".$prefix."_stories $qdb $querylang ORDER BY sid DESC LIMIT $start, $perpage"); //Added:LIMIT $start, $perpage
    while ($row = $db->sql_fetchrow($result)) {
   $s_sid = intval($row['sid']);
   $catid = intval($row['catid']);
    $aid = stripslashes($row['aid']);
    $title = stripslashes(check_html($row['title'], "nohtml"));
    $time = $row['time'];
    $hometext = stripslashes($row['hometext']);
    $bodytext = stripslashes($row['bodytext']);
    $comments = stripslashes($row['comments']);
    $counter = intval($row['counter']);
    $topic = intval($row['topic']);
    $informant = stripslashes($row['informant']);
    $notes = stripslashes($row['notes']);
   $acomm = intval($row['acomm']);
   $score = intval($row['score']);
   $ratings = intval($row['ratings']);
   if ($catid > 0) {
       $row2 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
       $cattitle = stripslashes(check_html($row2['title'], "nohtml"));
   }
   getTopics($s_sid);
   formatTimestamp($time);
   $subject = stripslashes(check_html($subject, "nohtml"));
   $introcount = strlen($hometext);
   $fullcount = strlen($bodytext);
   $totalcount = $introcount + $fullcount;
   $c_count = $comments;
   $r_options = "";
      if (isset($cookie[4])) { $r_options .= "&amp;mode=$cookie[4]"; }
      if (isset($cookie[5])) { $r_options .= "&amp;order=$cookie[5]"; }
      if (isset($cookie[6])) { $r_options .= "&amp;thold=$cookie[6]"; }
   $story_link = "<a href=\"modules.php?name=News&file=article&sid=$s_sid$r_options\">";
   $morelink = "(";
   if ($fullcount > 0 OR $c_count > 0 OR $articlecomm == 0 OR $acomm == 1) {
       $morelink .= "$story_link<b>"._READMORE."</b></a> | ";
   } else {
       $morelink .= "";
   }
   if ($fullcount > 0) { $morelink .= "$totalcount "._BYTESMORE." | "; }
   if ($articlecomm == 1 AND $acomm == 0) {
       if ($c_count == 0) { $morelink .= "$story_link"._COMMENTSQ."</a>"; } elseif ($c_count == 1) { $morelink .= "$story_link$c_count "._COMMENT."</a>"; } elseif ($c_count > 1) { $morelink .= "$story_link$c_count "._COMMENTS."</a>"; }
   }
   $sid = intval($s_sid);
   if ($catid != 0) {
       $row3 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
       $title1 = stripslashes(check_html($row3['title'], "nohtml"));
       $title = "<a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\"><font class=\"storycat\">$title1</font></a>: $title";
       $morelink .= " | <a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\">$title1</a>";
   }
   if ($score != 0) {
       $rated = substr($score / $ratings, 0, 4);
   } else {
       $rated = 0;
   }
   $morelink .= " | "._SCORE." $rated";
   $morelink .= ")";
   $morelink = str_replace(" |  | ", " | ", $morelink);
   themeindex($aid, $informant, $datetime, $title, $counter, $topic, $hometext, $notes, $morelink, $topicname, $topicimage, $topictext);
    }
      #Test New Page Numbers - http://www.codezwiz.com/kbview-55-ipb-like-page-numbers-function.html
   $add_url = ($new_topic > 0) ? '&amp;new_topic=' . $new_topic : ''; //is an added variable
      echo pagination('modules.php?name=' . $module_name . $add_url, $num_pages, $perpage, $start);
       #END New Page Numbers
   include("footer.php");
}

function rate_article($sid, $score) {
    global $prefix, $db, $ratecookie, $sitename, $r_options;
    $score = intval($score);
    $sid = intval($sid);
    if ($score) {
   if ($score > 5) { $score = 5; }
   if ($score < 1) { $score = 1; }
   if ($score != 1 AND $score != 2 AND $score != 3 AND $score != 4 AND $score != 5) {
       Header("Location: index.php");
       die();
   }
   if (isset($ratecookie)) {
       $rcookie = base64_decode($ratecookie);
       $rcookie = addslashes($rcookie);
       $r_cookie = explode(":", $rcookie);
   }
   for ($i=0; $i < sizeof($r_cookie); $i++) {
       if ($r_cookie[$i] == $sid) {
      $a = 1;
       }
   }
   if ($a == 1) {
       Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
   } else {
       $result = $db->sql_query("update ".$prefix."_stories set score=score+$score, ratings=ratings+1 where sid='$sid'");
       $info = base64_encode("$rcookie$sid:");
       setcookie("ratecookie","$info",time()+3600);
       Header("Location: modules.php?name=News&op=rate_complete&sid=$sid$r_options");
   }
    } else {
   include("header.php");
   title("$sitename: "._ARTICLERATING."");
   OpenTable();
   echo "<center>"._DIDNTRATE."<br><br>"
       .""._GOBACK."</center>";
   CloseTable();
   include("footer.php");
    }
}

function rate_complete($sid, $rated=0) {
    global $sitename, $user, $cookie;
    $r_options = "";
    if (is_user($user)) {
   if (isset($cookie[4])) { $r_options .= "&amp;mode=$cookie[4]"; }
   if (isset($cookie[5])) { $r_options .= "&amp;order=$cookie[5]"; }
        if (isset($cookie[6])) { $r_options .= "&amp;thold=$cookie[6]"; }
    }
    include("header.php");
    title("$sitename: "._ARTICLERATING."");
    OpenTable();
    if ($rated == 0) {
   echo "<center>"._THANKSVOTEARTICLE."<br><br>"
       ."[ <a href=\"modules.php?name=News&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
    } elseif ($rated == 1) {
   echo "<center>"._ALREADYVOTEDARTICLE."<br><br>"
       ."[ <a href=\"modules.php?name=News&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
    }
    CloseTable();
    include("footer.php");
}

switch ($op) {

    default:
    theindex($new_topic);
    break;

    case "rate_article":
    rate_article($sid, $score);
    break;

    case "rate_complete":
    rate_complete($sid, $rated);
    break;

}

?>




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
#9   re: News Page Number (want the new codezwiz version please)
prekill
CZ Newbie
prekill has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Jul 15, 2005
0.00 posts per day
Posts: 28
Points: 148
   
Hey,

Well its working great! I am using hebrew so I had to modify style.css and pagination.php:

style.css:
/* New Page Numbers */
.pagination {
   text-decoration: none;
   margin: 0px auto 0px auto;
}
.pagenumselect{
        font-size: 11px;
   background: #fff;
}
.pagenumhebrew{
   background: #fff;
   border: 1px solid #5379b8;
   padding: 2px 2px 0px 2px;
}
.pagenum,
.pagenumlast,
.pagecurrent{
   background: #fff;
   border: 1px solid #5379b8;
   padding: 1px 3px 1px 3px;
}
.pagenumlast{
   background: #efefef;
}
.pagecurrent{
   background: #cecece;
}
.pagenum a:active,
.pagenum a:visited,
.pagenum a:link,
.pagenumlast a:active,
.pagenumlast a:visited,
.pagenumlast a:link,
.pagecurrent a:active,
.pagecurrent a:visited,
.pagecurrent a:link{
   text-decoration: none;
}


pagination.php:
<?php
/*********************************************
  IPB emulation pagination
  ********************************************
  Copyright © 2002-2008 by Codezwiz Network, LLC.
  http://www.codezwiz.com/

  A free program released under the terms and conditions
  of the GNU GPL version 2 or any later version

  IPB like page numbers, for support goto http://www.codezwiz.com
  Instructions: http://www.codezwiz.com/kbview-55-ipb-like-page-numbers-function.html
***********************************************************************/
function pagination($page_url, $num_pages, $per_page, $start_page, $prevnext = true) {
   $total_pages = ceil($num_pages/$per_page);
   $on_page = floor($start_page / $per_page) + 1;
   $max_links_shown = 5;
   if ($total_pages == 1) { return ''; }
   $pagination = '';
   if($total_pages > 1) {
      $pagination .= "<div class=\"pagination\"><br />\n";
      if(($max_links_shown%2 != 0)) {
         $first_link = $on_page - (($max_links_shown - 1)/2);
         $last_link = $on_page + (($max_links_shown - 1)/2);
      } else {
         $first_link = $on_page - ($max_links_shown/2) + 1;
         $last_link = $on_page + ($max_links_shown/2);
      }
      if($first_link < 1) {
         $last_link -= ($first_link-1);
         $first_link = 1; //set first link to one
      }
      if($last_link > $total_pages) {
         if ($first_link > 1) {
            $first_link -= ($last_link-$total_pages);
            if ($first_link < 1) {
               $first_link = 1;
            }
         }
         $last_link = $total_pages;
      }
      $show_on_page = "$on_page î-$total_pages òîåãéí";
      if ($total_pages > 5) {
         $pagination .= "<span class=\"pagenumhebrew\">$show_on_page</span>&nbsp;";
         $pagination .= "<select class=\"pagenumselect\" name=\"generate_pagination\" onchange=\"jumpto(this);\">";
         for($i = 1; $i <= $total_pages; $i++) {
            $selected = ( $i == $on_page ) ? ' selected="selected"' : ''; // highlight current page by default
            $pagination .= '<option value="' . $page_url . '&start=' . ( ( $i - 1 ) * $per_page ) . '"' . $selected . '>' . $i . '</option>';
         }
         $pagination .= '</select> ';
      }
      if ($on_page > 1) {
            $idp  = $on_page;
         $add = $start_page - $per_page;
         if ($on_page > 2) {
            if ($prevnext) {
                  $pagination .= "<span class=\"pagenumlast\"><a href=\"" . $page_url . "\" title=\"Go to first page\">«</a></span> ";
            }
         }
         if ($prevnext) {
               $pagination .= "<span class=\"pagenum\"><a title=\"Previous page\" href=\"" . $page_url . "&start=" . $add . "\"><</a></span> ";
         }
      }
      for($idp = $first_link; $idp <= $last_link; $idp++) {
         if ($idp == $on_page) {
               $pagination .= "<span class=\"pagecurrent\">$idp</span> "; // no need to create a link to current page
         } else {
               $pagination .= "<span class=\"pagenum\"><a title=\"$idp\" href=\"".$page_url . "&start=" . ( ( $idp - 1 ) * $per_page ) . "\">$idp</a></span> ";
         }
      }
      if ($on_page < $total_pages) {
         if ($start_page > 0) {
            $idp = $on_page * $per_page;
         } else {
            $idp = $per_page;
         }
         $nstart = ($total_pages - 1) * $per_page;
         if ($prevnext) {
            $pagination .= "&nbsp;&nbsp;<span class=\"pagenum\"><a title=\"Next page\" href=\"" . $page_url . "&start=" . $idp . "\">></a></span> ";
         }
         if ($on_page < $total_pages - 2) {
            if ($prevnext) {
               $pagination .= "<span class=\"pagenumlast\"><a title=\"Go to last page\" href=\"" . $page_url . "&start=" .$nstart . "\">»</a></span>";
            }
         }
      }
      $pagination .= "</div>\n";
      return $pagination;
   }
}


Few problems:

I am using Google Tap, same as here. but the url now is:

modules.php?name=News&start=4
modules.php?name=News&start=16

and go on till 272...

How do I make it .html again?

another problem is when I choose a topic it wont navegate the url shows:
article-topic-7.html&start=4
article-topic-7.html&start=8

I think it is happaning because the &start=8 after the html ends.

How do I googletap those links?

here is my GT-News.php:
<?php

$urlin = array(
"'(?<!/)modules.php\?name=News&amp;file=article&amp;sid=([0-9]*)&amp;mode=([a-z]*)&amp;order=([0-9]*)&amp;thold=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;new_topic=([0-9]*)&amp;pagenum=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;file=categories&amp;op=newindex&amp;catid=([0-9]*)&amp;pagenum=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;file=categories&amp;op=newindex&amp;catid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;file=print&amp;sid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;file=friend&amp;op=FriendSend&amp;sid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;pagenum=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;file=article&amp;op=newindex&amp;catid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;file=article&amp;sid=([0-9]*)'",
"'(?<!/)modules.php\?name=News&amp;new_topic=([0-9]*)'",
"'\"(?<!/)modules.php\?name=News\"'",
"'(?<!/)modules.php\?name=Search&amp;author=([a-zA-Z0-9_-]*)'",
"'(?<!/)modules.php\?name=Search&amp;topic=([0-9]*)'",
"'(?<!/)modules.php\?name=Your_Account&amp;op=([a-z_]*)'",
"'(?<!/)modules.php\?name=Topics'"
);

$urlout = array(
"article-\\1-\\2-\\3-\\4.html",
"article-topic\\1-page\\2.html",
"article-category\\1-page\\2.html",
"article-category-\\1.html",
"article-print-\\1.html",
"article-friend-\\1.html",
"article-page-\\1.html",
"article-cat-\\1.html",
"article\\1.html",
"article-topic-\\1.html",
"\"news.html\"",
"search-author-\\1.html",
"search-\\1.html",
"account-\\1.html",
"topics.html"
);

?>


The .htaccess for news:
#Articles
RewriteRule ^article-([0-9]*)-([a-z]*)-([0-9]*)-([0-9]*).html modules.php?name=News&file=article&sid=$1&mode=$2&order=$3&thold=$4
RewriteRule ^article-([0-9-]*)-([a-z]*)-([0-9]*)-([0-9]*).html([0-9#]*) modules.php?name=News&file=article&thold=$1&mode=$2&order=$3&sid=$4$5
RewriteRule ^article-topic([0-9]*)-page([0-9]*).html modules.php?name=News&new_topic=$1&pagenum=$2
RewriteRule ^article-category([0-9]*)-page([0-9]*).html modules.php?name=News&file=categories&op=newindex&catid=$1&pagenum=$2
RewriteRule ^article-category-([0-9]*).html modules.php?name=News&file=categories&op=newindex&catid=$1
RewriteRule ^article-print-([0-9]*).html modules.php?name=News&file=print&sid=$1
RewriteRule ^article-friend-([0-9]*).html modules.php?name=News&file=friend&op=FriendSend&sid=$1
RewriteRule ^article-page-([0-9]*).html modules.php?name=News&pagenum=$1
RewriteRule ^article([1-9][0-9]*).* modules.php?name=News&file=article&sid=$1
RewriteRule ^article-topic-([0-9]*).html modules.php?name=News&new_topic=$1
RewriteRule ^allnews.html modules.php?name=News&file=allindex
RewriteRule ^news.html modules.php?name=News


Thanks for everything,

Will love to continue and add this script to the rest of the modules...

Thank you very much!


Back to top Reply with quote
#10   
Telli
Site Admin
Occupation: Self Employed
Age: 46
Gender: Male
Fav. Sports Team: Detroit Red Wings
Website:
Status: Offline
Joined: May 26, 2003
1.03 posts per day
Posts: 8089
Points: 494,430
   
In your google tap file just change all the pagenum to start. Example:


"'(?<!/)modules.php\?name=News&amp;new_topic=([0-9]*)&amp;pagenum=([0-9]*)'",


Becomes:


"'(?<!/)modules.php\?name=News&amp;new_topic=([0-9]*)&amp;start=([0-9]*)'",




_________________
The path of the righteous man is beset on all sides by the inequities of the selfish and the tyranny of evil men. Blessed is he, who in the name of charity and good will, shepherds the weak through the valley of darkness, for he is truly his brother's keeper and the finder of lost children. And I will strike down upon thee with great vengeance and furious anger those who would attempt to poison and destroy my brothers. And you will know my name is the Lord when I lay my vengeance upon thee. Ezekiel 25:17
Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum