[:"red"]
Mod Name / Version: TopNews Hack 1.0.1
Description: An easy way to place a short urgent new on top of the board.
Author(s): Carl Erling (caymuc)
Originally By:
Date: 4/Jan/03
Updates: 5/Jan/03,
Working under: UBB.threads 6.2
Any pre-requisites: none.
Files Altered: ubbt.inc.php, /admin/menu.php
Database Altered: No.
New Files: one empty file for the included-folder
Special Notes: Quick and dirty hack to display an urgent warning or news on top of the board. Something everybody will notice right away. Ment only for news with one short text-string. Text can be put in from the ADMIN menu just like the header include. - Yes also good for "Happy new Year!" displays <img src="/threads/php/images/graemlins/smile.gif" alt="" />
Is there a better place for the news?
Maybe where the birthdaygreeting goes?
[/]
----------------------------------------------------
Here's the HACK:
1.
In ADMIN / MENU.PHP, look for
<b>Includes</b>
</td></tr>
<tr><td valign=top class=lighttable>
and add right underneath:
<!-- TopNews Hack 1.0 -->
<a href="{$config['phpurl']}/admin/editincludes.php?Cat=$Cat&include=topnews" target="mainFrame">
Edit Topnews-Line
</a>
<br>
<!-- TopNews Hack end -->
2.
Put a new empty file in your includes folder.
Name it:
"topnews.php"
In UBBT.INC.PHP, find
// ----------------------------------------------------
// If they have private messages we give the PM flasher
// as long as they didn't just log out
and add ABOVE it:
// TopNews-Hack 1.0 by Carl Erling (caymuc)
// ----------------------------
// require the topnews.php include file
if (!$debug) {
echo "<div align="center"><table width="90%" border="0" cellspacing="0" cellpadding="2"><tr><td align="center" valign="middle">";
@include "$thispath/includes/topnews.php";
echo "</td></tr></table></div>";
}
// TopNews-Hack end
That's it. Hope you like it.
Last edited by JoshPet; 07/23/2003 10:22 PM.