"; OpenTable(); echo "
"._NEWLINKS."

"; $counter = 0; $allweeklinks = 0; while ($counter <= 7-1){ $newlinkdayRaw = (time()-(86400 * $counter)); $newlinkday = date("d-M-Y", $newlinkdayRaw); $newlinkView = date("F d, Y", $newlinkdayRaw); $newlinkDB = Date("Y-m-d", $newlinkdayRaw); $result = $db->sql_query("select * FROM ".$prefix."_links_links WHERE date LIKE '%$newlinkDB%'"); $totallinks = $db->sql_numrows($result); $counter++; $allweeklinks = $allweeklinks + $totallinks; } $counter = 0; while ($counter <=30-1){ $newlinkdayRaw = (time()-(86400 * $counter)); $newlinkDB = Date("Y-m-d", $newlinkdayRaw); $result = $db->sql_query("select * FROM ".$prefix."_links_links WHERE date LIKE '%$newlinkDB%'"); $totallinks = $db->sql_numrows($result); $allmonthlinks = $allmonthlinks + $totallinks; $counter++; } echo "
"._TOTALNEWLINKS.": "._LASTWEEK." - $allweeklinks \ "._LAST30DAYS." - $allmonthlinks
" .""._SHOW.": "._1WEEK." - "._2WEEKS." - "._30DAYS."" ."

"; /* List Last VARIABLE Days of Links */ if (!isset($newlinkshowdays)) { $newlinkshowdays = 7; } echo "
"._TOTALFORLAST." $newlinkshowdays "._DAYS.":

"; $counter = 0; $allweeklinks = 0; while ($counter <= $newlinkshowdays-1) { $newlinkdayRaw = (time()-(86400 * $counter)); $newlinkday = date("d-M-Y", $newlinkdayRaw); $newlinkView = date("F d, Y", $newlinkdayRaw); $newlinkDB = Date("Y-m-d", $newlinkdayRaw); $result = $db->sql_query("select * FROM ".$prefix."_links_links WHERE date LIKE '%$newlinkDB%'"); $totallinks = $db->sql_numrows($result); $counter++; if ($totallinks > 0) { $totallinks = "$totallinks"; } $allweeklinks = $allweeklinks + $totallinks; echo "· $newlinkView ($totallinks)
"; } $counter = 0; $allmonthlinks = 0; echo "
"; CloseTable(); @include("footer.php"); } // ###################################################################### // FUNCTION : NewLinksDate($selectdate) // ###################################################################### function NewLinksDate($selectdate) { global $prefix, $db, $admin, $user, $admin_file; $admin = base64_decode($admin); $admin = explode(":", $admin); $aid = "$admin[0]"; $result3 = $db->sql_query("select radminsuper from ".$prefix."_authors where aid='$aid'"); list($radminsuper) = sql_fetch_array($result3); $dateDB = (date("d-M-Y", $selectdate)); $dateView = (date("F d, Y", $selectdate)); @include("header.php"); menu(1); echo "
"; OpenTable(); $newlinkDB = Date("Y-m-d", $selectdate); $result = $db->sql_query("select * FROM ".$prefix."_links_links WHERE date LIKE '%$newlinkDB%'"); $totallinks = $db->sql_numrows($result); echo "$dateView - $totallinks "._NEWLINKS."" ."
"; $result=$db->sql_query("select lid, cid, sid, title, description, date, hits, linkratingsummary, totalvotes, totalcomments from ".$prefix."_links_links where date LIKE '%$newlinkDB%' order by title ASC"); while(list($lid, $cid, $sid, $title, $description, $time, $hits, $linkratingsummary, $totalvotes, $totalcomments)=$db->sql_fetchrow($result)) { $linkratingsummary = number_format($linkratingsummary, $mainvotedecimal); $title = stripslashes($title); $description = stripslashes($description); echo "$title"; newlinkgraphic($datetime, $time); popgraphic($hits); echo "
"._DESCRIPTION.": $description
"; setlocale (LC_TIME, $locale); /* INSERT code for *editor review* here */ ereg ("([0-9]{4})-([0-9]{1,2})-([0-9]{1,2}) ([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2})", $time, $datetime); $datetime = strftime(""._LINKSDATESTRING."", mktime($datetime[4],$datetime[5],$datetime[6],$datetime[2],$datetime[3],$datetime[1])); $datetime = ucfirst($datetime); echo ""._ADDEDON.": $datetime "._HITS.": $hits"; $transfertitle = str_replace (" ", "_", $title); /* voting & comments stats */ if ($totalvotes == 1) { $votestring = _VOTE; } else { $votestring = _VOTES; } if ($linkratingsummary!="0" || $linkratingsummary!="0.0") { echo " "._RATING.": $linkratingsummary ($totalvotes $votestring)"; } echo "
"; $result2=$db->sql_query("select title from ".$prefix."_links_categories where cid=$cid"); list($ctitle) = $db->sql_fetchrow($result2); $ctitle=getparent($cid,$ctitle); echo ""._CATEGORY.": $ctitle"; echo "
"; if ($radminsuper==1) { echo ""._EDIT." | "; } echo ""._RATESITE.""; if (is_user($user)) { echo " | "._REPORTBROKEN.""; } echo " | "._DETAILS.""; if ($totalcomments != 0) { echo " | "._SCOMMENTS." ($totalcomments)"; } detecteditorial($lid, $transfertitle); echo "

"; } echo "
"; CloseTable(); @include("footer.php"); } ?>