Location: PHPKode > projects > ViperWeb Portal System > httpdocs/themes/ViperWebPortal/theme.php
<?php

$bgcolor1 = "#024475";
$bgcolor2 = "#023D68";
$bgcolor3 = "#024475";
$bgcolor4 = "#023D68";
$textcolor1 = "#A0B8C9";
$textcolor2 = "#BACBD8";

function OpenTable() {
    global $bgcolor1, $bgcolor2;
    echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" bgcolor=\"$bgcolor2\"><tr><td>\n";
    echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"8\" bgcolor=\"$bgcolor1\"><tr><td>\n";
}

function OpenTable2() {
    global $bgcolor1, $bgcolor2;
    echo "<table border=\"0\" cellspacing=\"1\" cellpadding=\"0\" bgcolor=\"$bgcolor2\" align=\"center\"><tr><td>\n";
    echo "<table border=\"0\" cellspacing=\"1\" cellpadding=\"8\" bgcolor=\"$bgcolor1\"><tr><td>\n";
}

function CloseTable() {
    echo "</td></tr></table></td></tr></table>\n";
}

function CloseTable2() {
    echo "</td></tr></table></td></tr></table>\n";
}

function FormatStory($thetext, $notes, $aid, $informant) {
    global $anonymous;
    if ($notes != "") {
	$notes = "<b>"._NOTE."</b> <i>$notes</i>\n";
    } else {
	$notes = "";
    }
    if ("$aid" == "$informant") {
	echo "<font class=\"content\">$thetext<br>$notes</font>\n";
    } else {
	if($informant != "") {
	    $boxstuff = "<a href=\"index.php?mod=Your_Account&amp;op=userinfo&amp;uname=$informant\">$informant</a> ";
	} else {
	    $boxstuff = "$anonymous ";
	}
	$boxstuff .= ""._WRITES." <i>\"$thetext\"</i> $notes\n";
	echo "<font class=\"content\">$boxstuff</font>\n";
    }
}

function themeheader() {
    echo "<body bgcolor=\"024475\" text=\"A0B8C9\" link=\"C0C0C0\" vlink=\"CCCCCC\">"
	."<br>";
    if ($banners) {
	include("banners.php");
    }
    echo "<br>"
	."<br><br><br><br><br><br><br><table border=\"0 cellpadding=\"4\" cellspacing=\"0\" width=\"100%\" align=\"center\"><tr><td bgcolor=\"023D68\">";
        
      echo ?><div align="center">
 <center>
 <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" id="AutoNumber1" bgcolor="#024475">
  <tr>
   <td width="275" rowspan="2"><img border="0" src="themes/ViperWebPortal/images/theme1.jpg" width="275" height="100"></td>
   <td>
   <p align="center"></p>
   <form action="\%22index.php?mod=Search" method="post">
    <p align="right"><font class="content">Search:<input type="text" name="query" size="20"> </font></p>
   </form>
   </td>
   <td width="200" rowspan="2"><img border="0" src="themes/ViperWebPortal/images/theme2.jpg" width="200" height="100"></td>
  </tr>
  <tr>
   <td valign="bottom">
   <p align="center"><a href="index.php">Home</a> | <a href="index.php?mod=Downloads">Downloads</a> | <a href="index.php?mod=Web_Links">Web Link</a> | <a href="index.php?mod=Your_Account">Your Account</a> </td>
  </tr>
 </table>
 </center>
</div><?php  

        echo "</td></tr></table></td></tr><tr><td valign=\"top\" width=\"100%\" bgcolor=\"024475\">"
."<table border=\"0\" cellspacing=\"0\" cellpadding=\"2\" width=\"100%\"><tr><td valign=\"top\" width=\"150\" bgcolor=\"024475\">";
    blocks(left);
    echo "<img src=\"images/pix.gif\" border=\"0\" width=\"150\" height=\"1\"></td><td>&nbsp;&nbsp;</td><td width=\"100%\" valign=\"top\">";
}
function themefooter() {
    global $index;
    if ($index == 1) {
	echo "</td><td>&nbsp;&nbsp;</td><td valign=\"top\" bgcolor=\"#024475\">";
	blocks(right);
	echo "</td>";
    }
    echo "</td></tr></table></td></tr></table>";
    footmsg();
}

function themeindex ($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext) {
    global $anonymous;
    echo "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" align=\"center\" bgcolor=\"023D68\" width=\"100%\"><tr><td>"
        ."<table border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"100%\"><tr><td bgcolor=\"023D68\">"
        ."<b>$title</b><br>"
        ."<font class=\"tiny\">"
        .""._POSTEDBY." <b>";
    formatAidHeader($aid);
    echo "</b> "._ON." $time $timezone ($counter "._READS.")<br>"
	."<b>"._TOPIC."</b> <a href=\"index.php?mod=Search&amp;query=&amp;topic=$topic&amp;author=\">$topictext</a><br>"
	."</font></td></tr><tr><td bgcolor=\"024475\">";
    FormatStory($thetext, $notes, $aid, $informant);
    echo "<br><br>"
        ."</td></tr><tr><td bgcolor=\"024475\" align=\"right\">"
        ."<font class=\"content\">$morelink</font>"
        ."</td></tr></table></td></tr></table>"
	."<br>";
}

function themearticle ($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext) {
    global $admin, $sid;
    if ("$aid" == "$informant") {
	echo"
	<table border=0 cellpadding=0 cellspacing=0 align=center bgcolor=023D68 width=100%><tr><td>
	<table border=0 cellpadding=3 cellspacing=1 width=100%><tr><td bgcolor=024475>
	<b>$title</b><br><font class=tiny>".translate("Posted on ")." $datetime";
	if ($admin) {
	    echo "&nbsp;&nbsp; $font2 [ <a href=index.php?mod=Amin&op=EditStory&sid=$sid>".translate("Edit")."</a> | <a href=index.php?mod=Amin&op=RemoveStory&sid=$sid>".translate("Delete")."</a> ]";
	}
	echo "
	<br>".translate("Topic").": <a href=index.php?mod=Search&amp;query=&topic=$topic&author=>$topictext</a>
	</td></tr><tr><td bgcolor=024475>
	$thetext
	</td></tr></table></td></tr></table><br>";
    } else {
	if($informant != "") $informant = "<a href=\"index.php?mod=Your_Account&amp;op=userinfo&uname=$informant\">$informant</a> ";
	else $boxstuff = "$anonymous ";
	$boxstuff .= "".translate("writes")." <i>\"$thetext\"</i> $notes";
	echo "
	<table border=0 cellpadding=0 cellspacing=0 align=center bgcolor=023D68 width=100%><tr><td>
	<table border=0 cellpadding=3 cellspacing=1 width=100%><tr><td bgcolor=024475>
	<b>$title</b><br><font class=content>".translate("Contributed by ")." $informant ".translate("on")." $datetime</font>";
	if ($admin) {
	    echo "&nbsp;&nbsp; $font2 [ <a href=index.php?mod=Amin&op=EditStory&sid=$sid>".translate("Edit")."</a> | <a href=index.php?mod=Amin&op=RemoveStory&sid=$sid>".translate("Delete")."</a> ]";
	}
	echo "
	<br>".translate("Topic").": <a href=index.php?mod=Search&amp;query=&topic=$topic&author=>$topictext</a>
	</td></tr><tr><td bgcolor=024475>
	$thetext
	</td></tr></table></td></tr></table><br>";
    }
}

function themesidebox($title, $content) {
    echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"150\" bgcolor=\"023D68\"><tr><td>"
        ."<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"3\"><tr><td bgcolor=\"023D68\">"
        ."<font class=\"content\">$title</font></td></tr><tr><td bgcolor=\"024475\"><font class=\"content\">"
        ."$content"
	."</font></td></tr></table></td></tr></table><br>";
}

function themefloatingbox ($title, $content) {
    OpenTable();
    echo "<center><fon class=\"option\"><b>$title</b></font></center><br>"
	."$content";
    CloseTable();
    echo "<br>";
}

function themebottombox ($title, $content) {
    OpenTable();
    echo "<center><fon class=\"option\"><b>$title</b></font></center><br>"
	."$content";
    CloseTable();
    echo "<br>";
}
?>
Return current item: ViperWeb Portal System