home *** CD-ROM | disk | FTP | other *** search
/ PC World 2001 March / PCWorld_2001-03_cd.bin / KOMUNIK / progweb / progweb.exe / phpnuke / html / themes / Sunset / theme.php < prev   
PHP Script  |  2000-11-26  |  6KB  |  124 lines

  1. <?php
  2.  
  3. $bgcolor1 = "AAAAAA";
  4. $bgcolor2 = "006699";
  5. $textcolor1 = "FFFFFF";
  6. $textcolor2 = "FFFFFF";
  7.  
  8. function themepreview($title, $hometext, $bodytext="", $notes="") {
  9.     echo "<p><b>$title</b><br>$hometext<br><br>$bodytext $notes";
  10. }
  11.  
  12. function themesidebox($title, $content) {
  13.     mt_srand((double)microtime()*1000000);
  14.     $rcolor = mt_rand(1, 4);
  15.     if ($rcolor == 1) {
  16.     $tcolor = "006699";
  17.     } elseif ($rcolor == 2) {
  18.     $tcolor = "941C31";
  19.     } elseif ($rcolor == 3) {
  20.     $tcolor = "009983";
  21.     } elseif ($rcolor == 4) {
  22.     $tcolor = "0066FF";
  23.     }
  24.     echo "<table width=\"165\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td>\n";
  25.     echo "<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\"><tr><td>\n";
  26.     echo "<img src=\"themes/Sunset/left$rcolor.gif\" alt=\"\" border=\"0\" width=\"5\" height=\"19\"></td>\n";
  27.     echo "<td bgcolor=$tcolor width=\"100%\"><b><font size=\"2\" color=\"#FFFFFF\">$title</font></b></td>\n";
  28.     echo "<td align=\"right\"><img src=\"themes/Sunset/right$rcolor.gif\" alt=\"\" border=\"0\" width=\"5\" height=\"19\"></td></tr></table>\n";
  29.     echo "</td></tr><tr><td align=\"center\" valign=\"top\">\n";
  30.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"1\" bgcolor=$tcolor><tr><td width=100%>\n";
  31.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"4\" bgcolor=$tcolor><tr><td width=\"100%\" valign=\"top\" bgcolor=\"#FFFFE6\">\n";
  32.     echo "$content\n";
  33.     echo "<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\"><tr><td>\n";
  34.     echo "<img src=\"pixel.gif\" width=\"1\" height=\"4\" alt=\"\" border=\"0\"></td></tr></table>\n";
  35.     echo "</td></tr></table>\n";
  36.     echo "</td></tr></table>\n";
  37.     echo "</td></tr><tr>\n";
  38.     echo "<td align=\"center\" valign=\"bottom\">\n";
  39.     echo "<img width=\"100%\" height=\"5\" src=\"themes/Sunset/bottom$rcolor.gif\" vspace=\"0\" border=\"0\"></td></tr></table>\n";
  40.     echo "<br>\n\n";
  41. }
  42.  
  43. function themebigbox($title, $content) {
  44.     mt_srand((double)microtime()*1000000);
  45.     $rcolor = mt_rand(1, 4);
  46.     if ($rcolor == 1) {
  47.     $tcolor = "006699";
  48.     } elseif ($rcolor == 2) {
  49.     $tcolor = "941C31";
  50.     } elseif ($rcolor == 3) {
  51.     $tcolor = "009983";
  52.     } elseif ($rcolor == 4) {
  53.     $tcolor = "0066FF";
  54.     }
  55.     echo "<table width=100% border=\"0\" cellspacing=\"0\" cellpadding=\"0\"><tr><td>";
  56.     echo "<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\"><tr><td>";
  57.     echo "<img src=\"themes/Sunset/left$rcolor.gif\" alt=\"\" border=\"0\" width=\"5\" height=\"19\"></td>";
  58.     echo "<td bgcolor=$tcolor width=100%><b><font size=\"2\" color=\"#FFFFFF\">$title</font></b></td>";
  59.     echo "<td align=\"right\"><img src=\"themes/Sunset/right$rcolor.gif\" border=\"0\" width=\"5\" height=\"19\"></td></tr></table>";
  60.     echo "</td></tr><tr><td align=\"center\" valign=\"top\">";
  61.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"1\" bgcolor=$tcolor><tr><td width=100%>";
  62.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"4\" bgcolor=$tcolor><tr><td width=\"100%\" valign=\"top\" bgcolor=\"#FFFFE6\">";
  63.     echo "$content";
  64.     echo "<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\"><tr><td>";
  65.     echo "<img src=\"pixel.gif\" width=\"1\" height=\"4\" alt=\"\" border=\"0\"></td></tr></table>";
  66.     echo "</td></tr></table>";
  67.     echo "</td></tr></table>";
  68.     echo "</td></tr><tr>";
  69.     echo "<td align=\"center\" valign=\"bottom\">";
  70.     echo "<img width=\"100%\" height=\"5\" src=\"themes/Sunset/bottom$rcolor.gif\" vspace=\"0\" border=\"0\"></td></tr></table>";
  71.     echo "<br>";
  72. }
  73.  
  74. function themeindex($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext) {
  75.     global $tipath, $anonymous;
  76.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" bgcolor=035D8A><tr><td>\n";
  77.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"5\" bgcolor=FFFFFF><tr><td>\n";
  78.     echo "<a href=search.php?topic=$topic><img src=$tipath$topicimage Alt=\"$topictext\" border=0 align=right></a>\n";
  79.     echo "<font size=3><img src=\"themes/Sunset/bullet.gif\" border=0 hspace=3><b>$title</b><br>\n";
  80.     echo "<font size=1 color=035D8A>".translate("Posted by ")."";
  81.     formatAidHeader($aid);
  82.     echo " ".translate("on")." $time ($counter ".translate("reads").")<br><br>\n";
  83.     if ("$aid" == "$informant") {
  84.     echo "<font size=2 color=000000>$thetext<br><br>\n";
  85.     } else {
  86.     if ($informant != "") {
  87.         $boxstuff = "<a href=user.php?op=userinfo&uname=$informant>$informant</a> ";
  88.     } else {
  89.         $boxstuff = "$anonymous ";
  90.     }
  91.     $boxstuff .= "".translate("writes")." <i>\"$thetext\"</i> $notes\n";
  92.     echo "<font size=2 color=000000>$boxstuff<br><br>\n";
  93.     }
  94.     echo "<font size=2>$morelink<br><img src=themes/Sunset/line.gif border=0 vspace=4>\n";
  95.     echo "</td></tr></table>\n";
  96.     echo "</td></tr></table>\n";
  97.     echo "<br>\n\n";
  98. }
  99.  
  100. function themearticle($aid, $informant, $datetime, $title, $thetext, $topic, $topicname, $topicimage, $topictext) {
  101.     global $admin, $sid, $tipath;
  102.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" bgcolor=035D8A><tr><td>\n";
  103.     echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"5\" bgcolor=FFFFFF><tr><td>\n";
  104.     echo "<a href=search.php?topic=$topic><img src=$tipath$topicimage Alt=\"$topictext\" border=0 align=right></a>\n";
  105.     echo "<font size=3><img src=\"themes/Sunset/bullet.gif\" border=0 hspace=3><b>$title</b>\n";
  106.     if ($admin) {
  107.     echo "   [ <a href=admin.php?op=EditStory&sid=$sid>".translate("Edit")."</a> | <a href=admin.php?op=RemoveStory&sid=$sid>".translate("Delete")."</a> ]<br>\n";
  108.     } else {
  109.     echo "<br>\n";
  110.     }
  111.     echo "<font size=1 color=035D8A>".translate("Posted by ")."";
  112.     formatAidHeader($aid);
  113.     echo " ".translate("on")." $datetime<br>\n";
  114.     if ($informant != "") {
  115.         echo "".translate("Contributed by ")." <a href=user.php?op=userinfo&uname=$informant>$informant</a><br><br>\n";
  116.     } else {
  117.     echo "".translate("Contributed by ")." $anonymous<br><br>\n";
  118.     }
  119.     echo "<font size=2 color=000000>$thetext<br><br>\n";
  120.     echo "</td></tr></table>\n";
  121.     echo "</td></tr></table>\n\n";
  122. }
  123.  
  124. ?>