Code:<?php
if (!defined('PHP_EOL')) define ('PHP_EOL', strtoupper(substr(PHP_OS,0,3) == 'WIN') ? "\r\n" : "\n");
if (!defined('NUKE_FILE')) die ('You can\'t access this file directly...');
$bgcolor1 = '#1A1A1A';
$bgcolor2 = '#080808';
$bgcolor3 = '#1A1A1A';
$bgcolor4 = '#080808';
$textcolor1 = '#ffffff';
$textcolor2 = '#E00909';
/*
* To hide left-hand blocks for a given module, add an element to
* this array with the module name (directory name). To show the
* blocks, just remove the element from the array.
*/
$hide_blocks_left = array('Forums');
global $name;
if (!isset($name)) $name = '';
function themeheader() {
global $db, $prefix, $banners, $sitename, $user, $admin, $admin_file, $nukeurl, $slogan, $name, $nukeNAV;
echo '<body>' . PHP_EOL;
if ($banners) {
$adText = '';
$adText = ads(0);
if (!empty($adText)) {
echo '<div id="banner_pagetop">' . $adText . '</div>' . PHP_EOL;
}
};
echo '<div class="minmax">' . PHP_EOL
. ' <div id="header_wrap">' . PHP_EOL
. ' <div id="header">' . PHP_EOL
. ' <div id="head_content">' . PHP_EOL
. ' <a href="' . $nukeurl . '" title="' . $sitename . '"><img src="images/undergroundkinglogo.png" alt="' . $sitename . '" border="0" /></a>' . PHP_EOL
. ' </div>' . PHP_EOL;
if ($banners) {
echo ' <div id="head_ad">' . PHP_EOL
. ' '. ads(1)
. ' </div>' . PHP_EOL;
};
echo'</div>';
if (empty($nukeNAV)) {
echo '<div id="menu">' . PHP_EOL
. ' <div id="menu_links">' . PHP_EOL
. ' <ul>' . PHP_EOL
. ' <li><a href="index.php">' . _HOME . '</a></li>' . PHP_EOL
. ' <li><a href="modules.php?name=Downloads">' . _UDOWNLOADS . '</a></li>' . PHP_EOL
. ' <li><a href="modules.php?name=Your_Account">' . _FSIYOURACCOUNT . '</a></li>' . PHP_EOL
. ' <li><a href="forums.html">' . _BBFORUMS . '</a></li>' . PHP_EOL
. ' ' . (is_user($user) ? '<li><a href="modules.php?name=Your_Account&op=logout">' . _LOGOUT . '</a></li>' : '') . PHP_EOL
. ' ' . (is_admin($admin) ? '<li><a href="' . $admin_file . ' . php?op=adminMain">' . _FSIADMINMENU . '</a></li>' : '') . PHP_EOL
. ' </ul>' . PHP_EOL
. ' </div>' . PHP_EOL
. '<div id="menu_welcome">' . PHP_EOL;
} else {
echo '<div id="menunav">' . PHP_EOL;
echo $nukeNAV;
echo '<div id="menu_welcomenav">' . PHP_EOL;
}
if (is_user($user)) {
$uinfo = cookiedecode($user);
echo _BWEL . ' ' . stripslashes($uinfo[1]);
} else {
echo '<ul>' . PHP_EOL
. ' <li> <a href="modules.php?name=Your_Account">' . _LOGIN . '</a> ' . _OR . '</li>' . PHP_EOL
. ' <li><a href="modules.php?name=Your_Account&op=new_user">' . _BREG . '</a></li>' . PHP_EOL
. '</ul>' . PHP_EOL;
}
echo '</div>' . PHP_EOL
. '</div>' . PHP_EOL
. '</div>' . PHP_EOL
. '<div id="main_content">' . PHP_EOL;
global $hide_blocks_left;
if (in_array($name, $hide_blocks_left)) {
echo '<div id="middle_full">' . PHP_EOL; //<!-- center column -->
} else {
if(defined('INDEX_FILE') && INDEX_FILE===true) {
// right blocks are showing
echo '<div id="middle">' . PHP_EOL; //<!-- center column -->
} else {
// right blocks are NOT showing
echo '<div id="middle_alt">' . PHP_EOL; //<!-- center column -->';
}
}
}
function themefooter() {
global $db, $prefix, $name;
echo ' </div>' . PHP_EOL //<!-- end center column -->
. '</div>' . PHP_EOL; //<!-- end content -->
global $hide_blocks_left;
if (!in_array($name, $hide_blocks_left)) {
echo '<div id="left">' . PHP_EOL; //<!-- left column -->' . "\n";
blocks('l');
echo PHP_EOL . '</div>' . PHP_EOL; //<!-- end left column -->' . "\n";
}
if(defined('INDEX_FILE') && INDEX_FILE===true) { //display right blocks
echo '<div id="right">' . PHP_EOL; //<!-- start right column with right blocks -->
blocks('r');
echo '</div>' . PHP_EOL;// <!-- end right column with right blocks -->
} else { // don't display right blocks
echo '<div id="right">' . PHP_EOL //<!-- start right column no right blocks -->
. '</div>' . PHP_EOL; // <!-- end right column no right blocks -->
}
echo '<div style="clear: both"></div>' . PHP_EOL
. '<div id="footer">' . PHP_EOL
. LGL_MENU_HTML;
footmsg();
echo '</div>' . PHP_EOL
. '</div>' . PHP_EOL;
}
$GLOBALS['nest_count'] = 0;
function OpenTable() {
$GLOBALS['nest_count']++;
if ($GLOBALS['nest_count'] % 2 == 0) {
echo '<div class="block">' . PHP_EOL
. ' <div class="block_gradient">' . PHP_EOL
. ' <div> </div>' . PHP_EOL
. ' </div>' . PHP_EOL
. ' <div class="block_content">' . PHP_EOL;
} else {
echo '<div class="article">' . PHP_EOL
. ' <div class="article_top"></div>' . PHP_EOL
. ' <div class="article_content">' . PHP_EOL;
}
}
function CloseTable() {
echo '</div>' . PHP_EOL;
echo ($GLOBALS['nest_count'] % 2 == 0) ? '<div class="inv_article_bot">' . PHP_EOL : '<div class="article_bot">' . PHP_EOL;
echo '<div> </div></div>
</div>
';
$GLOBALS['nest_count']--;
}
function OpenTable2() {
OpenTable();
}
function CloseTable2() {
CloseTable();
}
function themesidebox($title, $content, $bid='') {
static $nobid;
if (empty($title)){
$btitle = ' ';
} else {
$btitle = $title;
}
if (!empty($bid)){
$BlockID = 'sideblock' . $bid;
} else {
if (isset($nobid)){
$nobid++;
} else {
$nobid=1;
}
$BlockID = 'otherblock' . $nobid;
}
echo '<div class="block">' . PHP_EOL
. ' <div class="block_top">' . PHP_EOL
. ' <h3>' . $title . '</h3>' . PHP_EOL
. ' </div>' . PHP_EOL
. ' <div class="block_content">' . PHP_EOL
. ' ' . $content . PHP_EOL
. ' </div>' . PHP_EOL
. ' <div class="article_bot"></div>' . PHP_EOL
. '</div>' . PHP_EOL;
}
function themecenterbox($title, $content, $bid = '') {
global $admin, $admin_file;
echo '<div class="block_center">' . PHP_EOL
. ' <div class="block_top">' . PHP_EOL
. ' <h3>' . $title . '</h3>' . PHP_EOL
. ' </div>' . PHP_EOL
. '<div class="article_content">' . PHP_EOL
. ' ' . $content . PHP_EOL;
if (is_admin($admin) && !empty($bid)) {
echo ' <br /><br />' . PHP_EOL
. ' <div class="text-center">' . PHP_EOL
. ' [ <a href="' . $admin_file . ' . php?op=BlocksEdit&bid=' . $bid . '">' . _EDIT . '</a> ]' . PHP_EOL
. ' </div>' . PHP_EOL;
}
echo '</div>' . PHP_EOL
. '<div class="article_bot"></div>' . PHP_EOL
. '</div>' . PHP_EOL;
}
function FormatStory($thetext, $notes, $aid, $informant) {
global $anonymous;
$content = '';
$thetext = '<div>' . $thetext . '</div>' . PHP_EOL;
if (!empty($notes)) {
$notes = '<br /><strong>' . _NOTE . '</strong> <div>' . $notes . '</div>' . PHP_EOL;
} else {
$notes = '';
}
if ($aid == $informant) {
$content = $thetext.$notes;
} else {
if(!empty($informant)) {
global $admin, $user;
if (is_user($user)|| is_admin($admin)) {
$content = '<a href="modules.php?name=Your_Account&op=userinfo&username=' . $informant . '"><span class="italic">' . $informant . '</span></a> ';
} else {
$content = $informant . ' ';
}
} else {
$content = $anonymous . ' ';
}
$content .= '<span class="italic">' . _WRITES . ':</span> ' . $thetext . $notes;
}
echo $content;
}
function themeindex ($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext) {
global $anonymous, $tipath;
echo '<div class="article">' . PHP_EOL
. ' <div class="article_top"></div>' . PHP_EOL
. ' <div class="article_content">' . PHP_EOL
. ' <div class="atitle">' . PHP_EOL
. ' <h2>' . $title .'</h2>' . PHP_EOL
. ' <p>' . PHP_EOL
. ' ' . _POSTEDON . ' ' . $time . ' ' . _IN . ' <a href="modules.php?name=News&new_topic=' . $topic . '">' . $topictext . '</a>' . PHP_EOL
. ' <br />' . _BY . ' ' . PHP_EOL;
formatAidHeader($aid);
echo ' </p>' . PHP_EOL
. ' </div>' . PHP_EOL
. '<div class="entry">' . PHP_EOL
. ' <blockquote>' . PHP_EOL
. ' <a href="modules.php?name=News&new_topic=' . $topic . '" title="' . $topictext . '"><img src="' . $tipath.$topicimage . '" border="0" alt="' . $topictext . '" title="' . $topictext . '" align="right" /></a>' . PHP_EOL;
FormatStory($thetext, $notes, $aid, $informant);
echo ' </blockquote>' . PHP_EOL
. '</div>' . PHP_EOL
//echo substr($morelink, 1, strlen($morelink) - 2); //get rid of the ( ) around the $morelink :)
//echo ' | ' . $counter . ' ' . _READS;
. '</div>' . PHP_EOL
. '<p class="links">' . $morelink . '</p> ' . PHP_EOL
. '<div class="article_bot"></div>' . PHP_EOL
. '</div>' . PHP_EOL
. '<br />' . PHP_EOL;
}
function themearticle ($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext, $notes) {
global $admin, $sid, $tipath;
echo '<div class="article">' . PHP_EOL
. ' <div class="article_top"></div>' . PHP_EOL
. ' <div class="article_content">' . PHP_EOL
. ' <div class="atitle">' . PHP_EOL
. ' <h2>' . $title . '</h2>' . PHP_EOL
. ' <p>' . PHP_EOL
. ' ' . _POSTEDON . ' ' . $datetime . ' ' . _IN . ' <a href="modules.php?name=News&new_topic=' . $topic . '">' . $topictext . ' </a><br /> ' . _BY . ' ' . PHP_EOL;
formatAidHeader($aid);
echo ' </p>' . PHP_EOL
. ' </div>' . PHP_EOL
. ' </div>' . PHP_EOL
. ' <div class="entry">' . PHP_EOL
. ' <blockquote>' . PHP_EOL;
FormatStory($thetext, $notes, $aid, $informant);
echo ' </blockquote>' . PHP_EOL
. ' </div>' . PHP_EOL
. '</div>' . PHP_EOL;
}
|