Archiv verlassen und diese Seite im Standarddesign anzeigen : Änderung im "Last Post on Forumhome and Forumdisplay" Hack (Version 1.2)
magicfox
27.08.2003, 16:41
Mit dem o.a. Hack kann man ja bekanntlich die letzten Themen eines Threads direkt auf der Startseite des Forums anzeigen. Wenn man nun einem dieser Links folgt, gelangt man aber generell zum neuesten Posting in diesem Thread. Wie erreiche ich, dass ich zum ERSTEN Beitrag dieses Threads komme?
magicfox
04.09.2003, 18:07
Vielleicht sollte ich noch weitere Details zu diesem Hack verraten. ;)
Im Template "forumhome_lastpostby" wird der letzte Beitrag so aufgerufen (direkt auf der Forumstartseite):
<a href="showthread.php?s=$session[sessionhash]&goto=lastpost&forumid=$forum[forumid]"><b><u>$forum[lastthread]</u></b></a>
Ein Klick auf diesen Link trägt den User direkt zum LETZTEN Posting im entsprechenden Thread. Wie kann ich festlegen, dass ich stattdessen in das ERSTE Posting des Threads komme?
magicfox
09.09.2003, 19:48
Kann wirklich niemand helfen? :(
lösche mal das
&goto=lastpost
in dem Link von dir
magicfox
11.09.2003, 19:30
So schlau war ich auch schon. ;)
Leider kommt beim Löschen diese Fehlermeldung:
Keine(n) thread angegeben. Wenn Du einem korrekten Link gefolgt bist, solltest Du den Administrator benachrichtigen.:(
magicfox
18.09.2003, 16:37
Ist das denn wirklich nicht irgendwie möglich? Kann mir gar nicht vorstellen, dass ich der einzige mit diesem Wunsch bin. :(
magicfox
28.09.2003, 16:56
:-(
magicfox
14.10.2003, 16:49
Ich versuche es einfach noch einmal. :)
showthread.php
Suche nach:
----------------------------------------------------------------------
if ( isset($goto) and ($goto=='lastpost' or $goto=='newpost')) {
$noheader=1;
}
----------------------------------------------------------------------
Ersetze es mit:
----------------------------------------------------------------------
if ( isset($goto) and ($goto=='lastpost' or $goto=='firstpost' or $goto=='newpost')) {
$noheader=1;
}
----------------------------------------------------------------------
Suche nach:
----------------------------------------------------------------------
// goto newest post
----------------------------------------------------------------------
Füge DARÜBER ein:
----------------------------------------------------------------------
// goto last thread
if ($goto=="firstpost") {
if (isset($forumid) and $forumid!=0) {
$foruminfo=verifyid("forum",$forumid,1,1);
$forumid=$foruminfo['forumid'];
$forumslist = "";
$getchildforums=$DB_site->query("SELECT forumid,parentlist FROM forum WHERE INSTR(CONCAT(',',parentlist,','),',$forumid,')>0");
while ($getchildforum=$DB_site->fetch_array($getchildforums)) {
if ($getchildforum[forumid]==$forumid) {
$parentlist=$getchildforum[parentlist];
}
$forumslist.=",$getchildforum[forumid]";
}
$thread=$DB_site->query_first("SELECT threadid FROM thread WHERE forumid IN (0$forumslist) AND visible=1 AND (sticky=1 OR sticky=0) AND lastpost>='".($foruminfo[lastpost]-30)."' AND open<>10 ORDER BY lastpost DESC LIMIT 1");
if ($getfirstpost=$DB_site->query_first("SELECT postid FROM post WHERE threadid='$thread[threadid]' AND visible=1 ORDER BY postid ASC LIMIT 1")) {
header("Location: showthread.php?s=$session[sessionhash]&postid=$getfirstpost[postid]" . iif(!empty($highlight), "&highlight=$highlight", "") . "#post$getfirstpost[postid]");
exit;
}
}
}
----------------------------------------------------------------------Ändere dann natürlich noch im Template lastpost in firstpost.
magicfox
15.10.2003, 18:48
Suuuuper, vielen vielen Dank! Funktioniert wunderbar. :)
Powered by vBulletin® Version 4.1.12 Copyright ©2012 Adduco Digital e.K. und vBulletin Solutions, Inc. Alle Rechte vorbehalten.