maj.world

maj.world

Git

This blob has been accessed 439 times via Git panel.

  1. <?php
  2.  
  3. ini_set("session.use_trans_sid", 0);
  4.  
  5. session_start();
  6.  
  7. if (isset($_SESSION['logged_in']) and ($_SESSION['user_agent'] != $_SERVER['HTTP_USER_AGENT'])) {
  8.         header("Location: http://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/login.php");
  9. }
  10.  
  11. header("Cache-control: private");
  12.  
  13. error_reporting(E_ERROR);
  14.  
  15. if (get_magic_quotes_gpc()) {
  16.         function stripslashes_array($data) {
  17.                 if (is_array($data)){
  18.                          foreach ($data as $key => $value){
  19.                                   $data[$key] = stripslashes_array($value);
  20.                          }
  21.                          return $data;
  22.                 }
  23.                 else{
  24.                          return stripslashes($data);
  25.                 }
  26.         }
  27.  
  28.         $_REQUEST = stripslashes_array($_REQUEST);
  29. }
  30.  
  31. $dir = "data/items";
  32.  
  33. $default_title = file_get_contents("data/title.txt");
  34.  
  35.  
  36. if (file_exists("data/offset.txt")) {
  37.         $offset = file_get_contents("data/offset.txt");
  38. }
  39. else {
  40.         $offset = 0;
  41. }
  42.  
  43. if (file_exists("data/increase.txt")) {
  44.         $increase = file_get_contents("data/increase.txt");
  45. }
  46. else {
  47.         $increase = 5;
  48. }
  49.  
  50. $default_blog_title = "My Activity Journal";
  51. $default_username = "maj";
  52. $default_password = "php";
  53. $default_blog_profile = "This cool site is powered by <a href=http://maj.sourceforge.net/ target=_maj>My Activity Journal</a>, a simple, <a href=http://php.net/ target=_maj>PHP</a>-based, <a href=http://www.opensource.org/licenses/gpl-license.php target=_maj>GPL</a>'ed blog written from scratch as a spare time family project by <a href=http://engels.mortega.net/ target=_maj>Engels</a>, <a href=http://gaffud.com/ target=_maj>Magie</a>, and <a href=http://psylocke.org/ target=_maj>Psylocke</a> Antonio.";
  54. $default_blog_author = "My Activity Journal";
  55.  
  56. if (!file_exists("data")) {
  57.         mkdir("data");
  58. }
  59.  
  60. if (!file_exists("data/.htaccess")) {
  61.         $htaccess = "Order deny,allow\nDeny from all";
  62.         $fp_htaccess_txt = fopen("data/.htaccess","w");
  63.         fwrite($fp_htaccess_txt, $htaccess);
  64.         fclose($fp_htaccess_txt);
  65. }
  66.  
  67. if (!file_exists("data/title.txt")) {
  68.         $fp_default_title_txt = fopen("data/title.txt","w");
  69.         fwrite($fp_default_title_txt, $default_blog_title);
  70.         fclose($fp_default_title_txt);
  71. }
  72.  
  73. if (!file_exists("data/username.txt")) {
  74.         $fp_htaccess_txt = fopen("data/username.txt","w");
  75.         fwrite($fp_htaccess_txt, $default_username);
  76.         fclose($fp_htaccess_txt);
  77. }
  78.  
  79. if (!file_exists("data/password.txt")) {
  80.         $default_password = sha1($default_password);
  81.         $default_password = md5($default_password);
  82.         $default_password = crypt($default_password, $default_password);
  83.         $fp_htaccess_txt = fopen("data/password.txt","w");
  84.         fwrite($fp_htaccess_txt, $default_password);
  85.         fclose($fp_htaccess_txt);
  86. }
  87.  
  88. if (!file_exists("data/profile.php")) {
  89.         $fp_default_profile_txt = fopen("data/profile.php","w");
  90.         fwrite($fp_default_profile_txt, $default_blog_profile);
  91.         fclose($fp_default_profile_txt);
  92. }
  93.  
  94. if (!file_exists("data/author.txt")) {
  95.         $fp_default_author_txt = fopen("data/author.txt","w");
  96.         fwrite($fp_default_author_txt, $default_blog_author);
  97.         fclose($fp_default_author_txt);
  98. }
  99.  
  100. $login_username = file_get_contents("data/username.txt");
  101.  
  102. if (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) {
  103.         $global_hits_file = fopen("data/hits.txt", "r");
  104.         $global_hits_count = fread($global_hits_file, filesize("data/hits.txt"));
  105.         fclose($global_hits_file);
  106.         $global_hits_count = $global_hits_count + 1;
  107.         $global_hits_file = fopen("data/hits.txt", "w");
  108.         fwrite($global_hits_file, $global_hits_count);
  109.         fclose($global_hits_file);
  110. }
  111.  
  112. $agent = $_SERVER['HTTP_USER_AGENT'];
  113.  
  114. if (@ereg("Google", $agent)) {
  115.         $google_hits_file = fopen("data/google.txt", "r");
  116.         $google_hits_count = fread($google_hits_file, filesize("data/google.txt"));
  117.         fclose($google_hits_file);
  118.         $google_hits_count = $google_hits_count + 1;
  119.         $google_hits_file = fopen("data/google.txt", "w");
  120.         fwrite($google_hits_file, $google_hits_count);
  121.         fclose($google_hits_file);
  122. }
  123.  
  124. function str_rand($length = 8, $seeds = 'abcdefghijklmnopqrstuvwxyz0123456789') {
  125.         $str = '';
  126.         $seeds_count = strlen($seeds);
  127.  
  128.         list($usec, $sec) = explode(' ', microtime());
  129.         $seed = (float) $sec + ((float) $usec * 100000);
  130.         mt_srand($seed);
  131.  
  132.         for ($i = 0; $length > $i; $i++) {
  133.                 $str .= $seeds{mt_rand(0, $seeds_count - 1)};
  134.         }
  135.         return $str;
  136. }
  137.  
  138. function rmdirr($recurse_dirname) {
  139.  
  140.         if (!file_exists($recurse_dirname)) {
  141.                 return false;
  142.         }
  143.  
  144.         if (is_file($recurse_dirname)) {
  145.                 return unlink($recurse_dirname);
  146.         }
  147.  
  148.         $recurse_dir = dir($recurse_dirname);
  149.  
  150.         while (false !== $recurse_entry = $recurse_dir->read()) {
  151.  
  152.                 if ($recurse_entry == '.' || $recurse_entry == '..') {
  153.                         continue;
  154.                 }
  155.  
  156.                 rmdirr("$recurse_dirname/$recurse_entry");
  157.         }
  158.  
  159.         $recurse_dir->close();
  160.         return rmdir($recurse_dirname);
  161. }
  162.  
  163. if (isset($_REQUEST['download']) and !empty($_REQUEST['download'])) {
  164.         ini_set('zlib.output_compression','off');
  165.         $file = str_replace('../','', @$_REQUEST['download']);
  166.         go_download($file);
  167.         die();
  168. }
  169.  
  170. function go_download($dl_file) {
  171.         $d = $_REQUEST['entry'];
  172.  
  173.         if (isset($_REQUEST['type']) and !empty($_REQUEST['type']) and ($_REQUEST['type'] == pdf)) {
  174.                 $dl_path = "data/items/$d/pdf/file";
  175.                 $count_path = "data/items/$d/pdf/count";
  176.                 $count_file = "dl.txt";
  177.         }
  178.  
  179.         if (isset($_REQUEST['type']) and !empty($_REQUEST['type']) and ($_REQUEST['type'] == filedrop)) {
  180.                 $dl_path = "data/items/$d/filedrop/files";
  181.                 $count_path = "data/items/$d/filedrop/count";
  182.                 $count_file = "{$dl_file}.txt";
  183.         }      
  184.  
  185.         header("Cache-Control: ");
  186.         header("Pragma: ");
  187.         header("Content-type: application/octet-stream");
  188.         header("Content-Disposition: attachment; filename=\"" . $dl_file . "\"");
  189.         header("Content-length: " . filesize("$dl_path/$dl_file"));
  190.         $get_it = fopen("$dl_path/$dl_file", 'rb');
  191.  
  192.         while (!feof($get_it)) {
  193.                 $buf = fread($get_it, 4096);
  194.                 echo $buf;
  195.                 $bytes_sent+=strlen($buf);
  196.         }
  197.  
  198.         if ($bytes_sent==filesize("$dl_path/$dl_file")) {
  199.  
  200.                 if (!file_exists($count_path)) {
  201.                         mkdir($count_path);
  202.                 }
  203.  
  204.                 $unique_downloads = "$count_path/$count_file";
  205.                 $fp_unique_downloads = fopen($unique_downloads, "r");
  206.                 $count_unique_downloads = fread($fp_unique_downloads, filesize($unique_downloads));
  207.                 fclose($fp_unique_downloads);
  208.                 $count_unique_downloads = $count_unique_downloads + 1;
  209.                 $fp_unique_downloads = fopen($unique_downloads, "w");
  210.                 fwrite($fp_unique_downloads, $count_unique_downloads);
  211.                 fclose($fp_unique_downloads);
  212.         }
  213. }
  214.  
  215. if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['comment']) and !empty($_REQUEST['comment']) and isset($_REQUEST['key']) and !empty($_REQUEST['key']) and isset($_REQUEST['action']) and !empty($_REQUEST['action'])) {
  216.  
  217.                 $comment_dir = "data/items/{$_REQUEST['entry']}/comments/pending/{$_REQUEST['comment']}";
  218.                 $key_file = "$comment_dir/key.txt";
  219.                 $open_key_file = fopen($key_file,"r");
  220.                 $login_key = fread($open_key_file,filesize($key_file));
  221.                 fclose($open_key_file);
  222.  
  223.                 if ($_REQUEST['key'] == $login_key) {
  224.  
  225.                         if ($_REQUEST['action'] == "approve") {
  226.  
  227.                                 $live_dir = "data/items/{$_REQUEST['entry']}/comments/live/{$_REQUEST['comment']}";
  228.                                 rename($comment_dir, $live_dir);
  229.                                 unlink("$live_dir/key.txt");
  230.  
  231.                                 $cat_dir = file_get_contents("data/items/{$_REQUEST['entry']}/category.txt");
  232.  
  233.                                 if (file_exists("data/members/active") and file_exists("data/ml.txt") and file_exists("data/email.txt") and !file_exists("data/items/{$_REQUEST['entry']}/private.txt") and !file_exists("data/categories/$cat_dir/private.txt")) {
  234.  
  235.                                         if (file_exists("data/ml-reply2.txt")) {
  236.                                                 $ml_reply2 = file_get_contents("data/ml-reply2.txt");
  237.                                         }
  238.  
  239.                                         if (file_exists("data/ml-from.txt")) {
  240.                                                 $ml_from = $ml_reply2;
  241.                                         }
  242.                                         else {
  243.                                                 $ml_from = file_get_contents("$live_dir/email.txt");
  244.                                         }
  245.  
  246.                                         $ml_from = str_replace(" at ","@",$ml_from);
  247.  
  248.                                         $ml_from_firstname = file_get_contents("$live_dir/firstname.txt");
  249.                                         $ml_from_lastname = file_get_contents("$live_dir/lastname.txt");
  250.  
  251.                                         $ml_from = '"' . "$ml_from_firstname $ml_from_lastname" . '" <' . $ml_from . '>';
  252.  
  253.                                         $ml_subject = file_get_contents("data/items/{$_REQUEST['entry']}/title.txt");
  254.                                         if (file_exists("data/ml-prepend.txt")) {
  255.                                                 $ml_prepend = file_get_contents("data/ml-prepend.txt");
  256.                                                 $ml_subject = str_replace($ml_prepend,"",$ml_subject);
  257.                                                 $ml_subject = $ml_prepend . " " . $ml_subject;
  258.                                         }
  259.                                         $ml_subject = str_replace("Re:","",$ml_subject);
  260.                                         $ml_subject = "Re: " . $ml_subject;
  261.  
  262.                                         $ml_mailer = 'MAJ/0.14 (PHP/' . phpversion() . ')';
  263.  
  264.                                         $ml_body = file_get_contents("$live_dir/comment.txt");
  265.                                         $ml_body = str_replace('<br />', "\n", $ml_body);
  266.                                         $ml_body = str_replace('<img src=images/smileys/crying.png border=0>', ':((', $ml_body);
  267.                                         $ml_body = str_replace('<img src=images/smileys/frown.png border=0>', ':(', $ml_body);
  268.                                         $ml_body = str_replace('<img src=images/smileys/indifferent.png border=0>', ':|', $ml_body);
  269.                                         $ml_body = str_replace('<img src=images/smileys/laughing.png border=0>', ':D', $ml_body);
  270.                                         $ml_body = str_replace('<img src=images/smileys/lick.png border=0>', ':P', $ml_body);
  271.                                         $ml_body = str_replace('<img src=images/smileys/ohno.png border=0>', ':O', $ml_body);
  272.                                         $ml_body = str_replace('<img src=images/smileys/smile.png border=0>', ':)', $ml_body);
  273.                                         $ml_body = str_replace('<img src=images/smileys/surprised.png border=0>', '=)', $ml_body);
  274.                                         $ml_body = str_replace('<img src=images/smileys/undecided.png border=0>', ':\\', $ml_body);
  275.                                         $ml_body = str_replace('<img src=images/smileys/wink.png border=0>', ';)', $ml_body);
  276.                                         $ml_body = str_replace('&amp;','&',$ml_body);
  277.                                         $ml_body = str_replace('&lt;','<',$ml_body);
  278.                                         $ml_body = str_replace('&gt;','>',$ml_body);
  279.                                         $ml_body = str_replace('&reg;','(R)',$ml_body);
  280.  
  281.                                         if (file_exists("data/pf.txt") and file_exists("data/pf-badwords.txt")) {
  282.                                                 $badwords = file_get_contents("data/pf-badwords.txt");
  283.                                                 if (file_exists("data/pf-censor.txt")) {
  284.                                                         $censor = file_get_contents("data/pf-censor.txt");
  285.                                                 }
  286.                                                 else {
  287.                                                         $censor = "[expletive]";
  288.                                                 }
  289.                                                 $ml_body = preg_replace("/\b($badwords)\b/i",$censor,$ml_body);
  290.                                         }
  291.  
  292.                                         if (file_exists("data/ml-header.txt")) {
  293.                                                 $ml_header = file_get_contents("data/ml-header.txt");
  294.                                                 $ml_body = $ml_header . "\n\n" . $ml_body;
  295.                                         }
  296.  
  297.                                         $ml_url = $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/";
  298.                                         $ml_url = str_replace('//', '/', $ml_url);
  299.                                         $ml_url = "http://" . $ml_url . "index.php?entry={$_REQUEST['entry']}&show=comments";
  300.  
  301.                                         $ml_body = $ml_body . "\n\nPlease visit the following URL for the full thread:\n\n" . $ml_url;
  302.  
  303.                                         if (file_exists("data/items/{$_REQUEST['entry']}/member.txt")) {
  304.                                                 $ml_body = $ml_body . "\n\nYou need to login first to view the entry or to add a comment.";
  305.                                         }
  306.  
  307.                                         if (file_exists("data/ml-footer.txt")) {
  308.                                                 $ml_footer = file_get_contents("data/ml-footer.txt");
  309.                                                 $ml_body = $ml_body . "\n\n" . $ml_footer;
  310.                                         }
  311.  
  312.  
  313.                                         if ($dh_ml_member = opendir("data/members/active")) {
  314.                                                 while (($ml_member = readdir($dh_ml_member)) !== false) {
  315.                                                         if ($ml_member != "." && $ml_member != ".." && fnmatch("*", $ml_member)) {
  316.  
  317.                                                                 if (file_exists("data/members/active/$ml_member/noml.txt")) {
  318.                                                                         continue;
  319.                                                                 }
  320.  
  321.                                                                 if (file_exists("data/members/active/$ml_member/vacation.txt")) {
  322.                                                                         continue;
  323.                                                                 }
  324.  
  325.                                                                 $ml_to_firstname = file_get_contents("data/members/active/$ml_member/firstname.txt");
  326.                                                                 $ml_to_lastname = file_get_contents("data/members/active/$ml_member/lastname.txt");
  327.                                                                 $ml_to = file_get_contents("data/members/active/$ml_member/email.txt");
  328.                                                                 $ml_to = '"' . "$ml_to_firstname $ml_to_lastname" . '" <'. $ml_to . '>';
  329.  
  330.                                                                 if (file_exists("data/ml-reply2.txt")) {
  331.                                                                         mail($ml_to, $ml_subject, $ml_body,
  332.                                                                         "From: $ml_from\r\n" .
  333.                                                                         "Reply-To: $ml_reply2\r\n" .
  334.                                                                         "References: {$_REQUEST['entry']}\r\n" .
  335.                                                                         "X-Mailer: $ml_mailer");
  336.                                                                 }
  337.                                                                 else {
  338.                                                                         mail($ml_to, $ml_subject, $ml_body,
  339.                                                                         "From: $ml_from\r\n" .
  340.                                                                         "References: {$_REQUEST['entry']}\r\n" .
  341.                                                                         "X-Mailer: $ml_mailer");
  342.                                                                 }
  343.                                                         }
  344.                                                 }
  345.                                                 closedir($dh_ml_member);
  346.                                         }
  347.                                 }
  348.  
  349.                         }
  350.  
  351.                         if ($_REQUEST['action'] == "delete") {
  352.                                 rmdirr($comment_dir);
  353.                         }
  354.  
  355.                         $pending_comment_flag_dir = $_REQUEST['entry'];
  356.                         $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag_dir/count.txt","r");
  357.                         $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$pending_comment_flag_dir/count.txt"));
  358.                         fclose($fp_comment_count_txt);
  359.  
  360.                         if ($comment_count_value <= 1) {
  361.                                 rmdirr("data/comments/pending/$pending_comment_flag_dir");
  362.                         }
  363.                         else {
  364.                                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag_dir/count.txt","r");
  365.                                 $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$pending_comment_flag_dir/count.txt"));
  366.                                 fclose($fp_comment_count_txt);
  367.                                 $comment_count_value = $comment_count_value - 1;
  368.                                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag_dir/count.txt","w");
  369.                                 fwrite($fp_comment_count_txt, $comment_count_value);
  370.                                 fclose($fp_comment_count_txt);
  371.                         }
  372.  
  373.                         header("Location: http://{$_SERVER['HTTP_HOST']}" . dirname($_SERVER['PHP_SELF']) . "/index.php?entry={$_REQUEST['entry']}&show=comments");
  374.                 }
  375. }
  376.  
  377. if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry'])) {
  378.         $check = "$dir/{$_REQUEST['entry']}";
  379.  
  380.         if (file_exists("$check")) {
  381.                 $filter = $_REQUEST['entry'];
  382.                 echo '<title>';
  383.                 $title = "$check/title.txt";
  384.                 readfile($title);
  385.                 echo '</title>';
  386.                 $views = "$check/views.txt";
  387.  
  388.                 if ((!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  389.                         $fp_views = fopen($views, "r");
  390.                         $count_views = fread($fp_views, filesize($views));
  391.                         fclose($fp_views);
  392.                         $count_views = $count_views + 1;
  393.                         $fp_views = fopen($views, "w");
  394.                         fwrite($fp_views, $count_views);
  395.                         fclose($fp_views);
  396.                 }
  397.                
  398.                 if (isset($_REQUEST['show']) and !empty($_REQUEST['show']) and isset($_POST['captcha_put']) and !empty($_REQUEST['captcha_get']) and isset($_POST['firstname']) and !empty($_POST['firstname']) and isset($_POST['lastname']) and !empty($_POST['lastname']) and isset($_POST['email']) and !empty($_POST['email']) and isset($_POST['new_comment']) and !empty($_POST['new_comment']) and isset($_POST['captcha_put']) and !empty($_POST['captcha_put']) and ($_REQUEST['captcha_get'] == $_POST['captcha_put']) and (ereg("@", $_POST['email'])) and (ereg("\.", $_POST['email']))) {
  399.                
  400.                 if (!file_exists("$check/comments")) {
  401.                         mkdir("$check/comments");
  402.                 }
  403.                 if (!file_exists("$check/comments/pending")) {
  404.                         mkdir("$check/comments/pending");
  405.                 }
  406.  
  407.                 if (!file_exists("$check/comments/live")) {
  408.                         mkdir("$check/comments/live");
  409.                 }
  410.  
  411.                 // GNU date format
  412.                 //$timestamp = date("D M j H:i:s \P\H\T Y", time() + $offset);
  413.  
  414.                 // Simple PHP Blog format
  415.                 $timestamp = date("l, M j, Y, g:i A", time() + $offset);
  416.  
  417.                 $comment_entry_dir = date("YmdHis", time() + $offset);
  418.  
  419.                 mkdir("$check/comments/pending/$comment_entry_dir");
  420.  
  421.                 $body_content = ucfirst($_POST['new_comment']);
  422.                 $body_content = htmlentities($body_content, ENT_NOQUOTES);
  423.                 // $body_content = str_replace('href=', 'target=_maj href=', $body_content);
  424.                 $body_content = str_replace("\n", '<br />', $body_content);
  425.                 $body_content = trim($body_content);
  426.                 $body_content = str_replace(':((', '<img src=images/smileys/crying.png border=0>', $body_content);
  427.                 $body_content = str_replace(':(', '<img src=images/smileys/frown.png border=0>', $body_content);
  428.                 $body_content = str_replace(':|', '<img src=images/smileys/indifferent.png border=0>', $body_content);
  429.                 $body_content = str_replace(':D', '<img src=images/smileys/laughing.png border=0>', $body_content);
  430.                 $body_content = str_replace(':P', '<img src=images/smileys/lick.png border=0>', $body_content);
  431.                 $body_content = str_replace(':O', '<img src=images/smileys/ohno.png border=0>', $body_content);
  432.                 $body_content = str_replace(':)', '<img src=images/smileys/smile.png border=0>', $body_content);
  433.                 $body_content = str_replace('=)', '<img src=images/smileys/surprised.png border=0>', $body_content);
  434.                 $body_content = str_replace(':\\', '<img src=images/smileys/undecided.png border=0>', $body_content);
  435.                 $body_content = str_replace(';)', '<img src=images/smileys/wink.png border=0>', $body_content);
  436.  
  437.                 $fp_body_txt = fopen("$check/comments/pending/$comment_entry_dir/comment.txt","w");
  438.                 fwrite($fp_body_txt,$body_content);
  439.                 fclose($fp_body_txt);
  440.  
  441.                 $fp_timestamp_txt = fopen("$check/comments/pending/$comment_entry_dir/timestamp.txt","w");
  442.                 fwrite($fp_timestamp_txt,$timestamp);
  443.                 fclose($fp_timestamp_txt);
  444.  
  445.                 $fp_firstname_txt = fopen("$check/comments/pending/$comment_entry_dir/firstname.txt","w");
  446.                 $firstname = strtolower($_POST['firstname']);
  447.                 $firstname = ucwords($firstname);
  448.                 $firstname = trim($firstname);
  449.                 $firstname = htmlentities($firstname, ENT_NOQUOTES);
  450.                 fwrite($fp_firstname_txt,$firstname);
  451.                 fclose($fp_firstname_txt);
  452.  
  453.                 $fp_lastname_txt = fopen("$check/comments/pending/$comment_entry_dir/lastname.txt","w");
  454.                 $lastname = strtolower($_POST['lastname']);
  455.                 $lastname = ucwords($lastname);
  456.                 $lastname = trim($lastname);
  457.                 $lastname = htmlentities($lastname, ENT_NOQUOTES);
  458.                 fwrite($fp_lastname_txt,$lastname);
  459.                 fclose($fp_lastname_txt);
  460.  
  461.                 $fp_email_txt = fopen("$check/comments/pending/$comment_entry_dir/email.txt","w");
  462.                 $email = str_replace("@"," at ",$_POST['email']);
  463.                 $email = strtolower($email);
  464.                 $email = trim($email);
  465.                 $email = htmlentities($email, ENT_NOQUOTES);
  466.                 fwrite($fp_email_txt,$email);
  467.                 fclose($fp_email_txt);
  468.  
  469.                 if (isset($_POST['url']) and !empty($_POST['url']) and (ereg("\.", $_POST['url']))) {
  470.                         $fp_url_txt = fopen("$check/comments/pending/$comment_entry_dir/url.txt","w");
  471.                         $url = str_replace("http://","",$_POST['url']);
  472.                         $url = strtolower($url);
  473.                         $url = trim($url);
  474.                         $url = "http://" . $url;
  475.                         $url = htmlentities($url, ENT_NOQUOTES);
  476.                         fwrite($fp_url_txt,$url);
  477.                         fclose($fp_url_txt);
  478.                 }
  479.  
  480.                 if (isset($_POST['cauthor']) and !empty($_POST['cauthor'])) {
  481.                         $fp_cauthor_txt = fopen("$check/comments/pending/$comment_entry_dir/author.txt","w");
  482.                         fwrite($fp_cauthor_txt,$_POST['cauthor']);
  483.                         fclose($fp_cauthor_txt);
  484.                 }
  485.  
  486.                 $key_rand = str_rand(14);
  487.                 $fp_key_txt = fopen("$check/comments/pending/$comment_entry_dir/key.txt","w");
  488.                 fwrite($fp_key_txt,$key_rand);
  489.                 fclose($fp_key_txt);
  490.  
  491.                 $comment_quote = ucfirst($_POST['new_comment']);
  492.                 //$comment_quote = htmlentities($comment_quote, ENT_NOQUOTES);
  493.  
  494.                 $sig_author_file = "data/author.txt";
  495.                 $fp_sig_author = fopen($sig_author_file, "r");
  496.                 $sig_author = fread($fp_sig_author, filesize($sig_author_file));
  497.                 fclose($fp_sig_author);
  498.  
  499.                 $sig_url = $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/";
  500.                 $sig_url = str_replace('//', '/', $sig_url);
  501.                 $sig_url = "http://" . $sig_url;
  502.  
  503.                 $email_to = strtolower($_POST['email']);
  504.                 $email_to = '"' . "$firstname $lastname" . '" <' . $email_to . '>';
  505.  
  506.                 if (file_exists("data/email.txt")) {
  507.                         $from_email_author = file_get_contents("data/author.txt");
  508.                         $from_email = file_get_contents("data/email.txt");
  509.                         $from_email = '"' . $from_email_author . '" <' . $from_email . '>';
  510.                 }
  511.  
  512.                 $mailer = 'MAJ/0.14 (PHP/' . phpversion() . ')';
  513.  
  514.                 $commented_entry_title_file = "data/items/{$_REQUEST['entry']}/title.txt";
  515.                 $fp_commented_entry_title = fopen($commented_entry_title_file, "r");
  516.                 $commented_entry_title = fread($fp_commented_entry_title, filesize($commented_entry_title_file));
  517.                 fclose($fp_commented_entry_title);
  518.  
  519.                 if (!file_exists("data/nak.txt") and file_exists("data/email.txt")) {
  520.                         $comment_thanks = "Hi $firstname,\n\nThanks for submitting the following comment last $timestamp:\n\n\"$comment_quote\"\n\nIt will be e-mailed to me first for approval. Please visit the following URL to see if it has been posted:\n\n{$sig_url}index.php?entry={$_REQUEST['entry']}&show=comments\n\nThanks again! =)\n\n--\n$sig_author\n$sig_url\n";
  521.  
  522.                         $comment_thanks = wordwrap($comment_thanks);
  523.  
  524.                         mail($email_to, "Thanks for sharing your thoughts!", $comment_thanks,
  525.                                 "From: $from_email\r\n" .
  526.                                 "Reply-To: $from_email\r\n" .
  527.                                 "X-Mailer: $mailer");
  528.                 }
  529.  
  530.                 if (file_exists("data/email.txt")) {
  531.                         $comment_notice = "The following comment was submitted by $email_to last $timestamp for the entry \"$commented_entry_title\":\n\n\"$comment_quote\"\n\nVisit the link below to approve and post this pending comment:\n\n{$sig_url}index.php?entry={$_REQUEST['entry']}&comment={$comment_entry_dir}&key={$key_rand}&action=approve\n\nVisit the link below to disapprove and delete this pending comment:\n\n{$sig_url}index.php?entry={$_REQUEST['entry']}&comment={$comment_entry_dir}&key={$key_rand}&action=delete\n\nYou can also approve or disapprove pending comments at a later time by logging on to your blog.";
  532.  
  533.                         $comment_notice = wordwrap($comment_notice);
  534.  
  535.                         mail($from_email, "Pending Comment", $comment_notice,
  536.                                 "From: $from_email\r\n" .
  537.                                 "Reply-To: $from_email\r\n" .
  538.                                 "X-Mailer: $mailer");
  539.                 }
  540.  
  541.                 if (!file_exists("data/comments")) {
  542.                         mkdir("data/comments");
  543.                 }
  544.  
  545.                 if (!file_exists("data/comments/pending")) {
  546.                         mkdir("data/comments/pending");
  547.                 }
  548.  
  549.                 $pending_comment_flag = $_REQUEST['entry'];
  550.  
  551.                 if (!file_exists("data/comments/pending/$pending_comment_flag")) {
  552.                         mkdir("data/comments/pending/$pending_comment_flag");
  553.                 }
  554.  
  555.                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag/count.txt","r");
  556.                 $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$pending_comment_flag/count.txt"));
  557.                 fclose($fp_comment_count_txt);
  558.                 $comment_count_value = $comment_count_value + 1;
  559.                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag/count.txt","w");
  560.                 fwrite($fp_comment_count_txt, $comment_count_value);
  561.                 fclose($fp_comment_count_txt);
  562.  
  563.                 }
  564.  
  565.         }
  566.         else {
  567.                 echo '<title>' . $default_title . '</title>';
  568.                 if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  569.                         $filter = $_REQUEST['archive'] . "*";
  570.                 }
  571.                 else {
  572.                         $filter = "*";
  573.                 }
  574.         }
  575. }
  576. else {
  577.         echo '<title>' . $default_title . '</title>';
  578.         if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  579.                 $filter = $_REQUEST['archive'] . "*";
  580.         }
  581.         else {
  582.                 $filter = "*";
  583.         }
  584. }
  585.  
  586. // start: auto-approve comments without rewriting "comment approval system" (20080521)
  587.  
  588. if (file_exists("data/comments/pending") and file_exists("data/xscreen.txt")) {
  589.  
  590.         if ($dh_xscreen_list = opendir("data/comments/pending")) {
  591.  
  592.                 while (($entry_xscreen = readdir($dh_xscreen_list)) !== false) {
  593.  
  594.                         if ($entry_xscreen != "." && $entry_xscreen != "..") {
  595.                                 $show_xscreen_list[] = $entry_xscreen;
  596.                         }
  597.                 }
  598.                 closedir($dh_xscreen_list);
  599.         }
  600.  
  601.         rsort($show_xscreen_list);
  602.         reset($show_xscreen_list);
  603.  
  604.         if (count($show_xscreen_list) > 0) {
  605.  
  606.                 foreach ($show_xscreen_list as $xscreen_dir) {
  607.  
  608.                         if ($dh_xscreen_pending = opendir("data/items/$xscreen_dir/comments/pending")) {
  609.  
  610.                                 while (($xscreen_entry = readdir($dh_xscreen_pending)) !== false) {
  611.                                        
  612.                                         if ($xscreen_entry != "." && $xscreen_entry != "..") {
  613.  
  614.                                                 $xscreen_key = file_get_contents("data/items/$xscreen_dir/comments/pending/$xscreen_entry/key.txt");
  615.                                                 header("Location: http://{$_SERVER['HTTP_HOST']}" . dirname($_SERVER['PHP_SELF']) . "/index.php?entry={$xscreen_dir}&comment={$xscreen_entry}&key={$xscreen_key}&action=approve");
  616.                                         }
  617.                                 }
  618.                         }
  619.                 }
  620.  
  621.         }
  622. }
  623.  
  624. // end: auto-approve comments without rewriting "comment approval system" (20080521)
  625.  
  626. ?>
  627.  
  628. <?php
  629.  
  630. if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and file_exists("data/items/{$_REQUEST['entry']}")) {
  631.  
  632.         $cat_dir = file_get_contents("data/items/{$_REQUEST['entry']}/category.txt");
  633.  
  634.         if (!file_exists("data/categories/$cat_dir/private.txt")) {
  635.  
  636.                 if (!file_exists("data/items/{$_REQUEST['entry']}/passwd.txt")) {
  637.  
  638.                         if (!file_exists("data/items/{$_REQUEST['entry']}/private.txt")) {
  639.  
  640.                                 $description = file_get_contents("data/items/{$_REQUEST['entry']}/body.txt");
  641.                                 $description = strip_tags($description);
  642.                                 $description = html_entity_decode($description);
  643.                                 $description = str_replace("&","&amp;",$description);
  644.                                 $description = str_replace("<","&lt;",$description);
  645.                                 $description = str_replace(">","&gt;",$description);
  646.                                 $description = str_replace("<br>"," ",$description);
  647.                                 $description = str_replace("<br />"," ",$description);
  648.                                 $description = str_replace("\r"," ",$description);
  649.                                 $description = str_replace("\n"," ",$description);
  650.                                 $description = str_replace(chr(10)," ",$description);
  651.                                 $description = str_replace(chr(13)," ",$description);
  652.                                 $description = trim($description);
  653.                                 $description = substr($description,0,210);
  654.                                 $description = htmlentities($description, ENT_NOQUOTES);
  655.  
  656.                                                 if (file_exists("data/pf.txt") and file_exists("data/pf-badwords.txt") and (!isset($_SESSION['logged_in']) or empty($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt"))))) {
  657.                                         $badwords = file_get_contents("data/pf-badwords.txt");
  658.                                         if (file_exists("data/pf-censor.txt")) {
  659.                                                 $censor = file_get_contents("data/pf-censor.txt");
  660.                                         }
  661.                                         else {
  662.                                                 $censor = "[expletive]";
  663.                                         }
  664.                                         $description = preg_replace("/\b($badwords)\b/i",$censor,$description);
  665.                                 }
  666.  
  667.                                 echo "<meta name=\"description\" content=\"{$description}\">";
  668.                         }
  669.                 }
  670.         }
  671. }
  672.  
  673. ?>
  674.  
  675. <style>
  676.  
  677. body {
  678.         color: <?php
  679.                         if (file_exists("data/colors/font.txt")) {
  680.                                 $font_color = file_get_contents("data/colors/font.txt");
  681.                                 echo $font_color;
  682.                         }
  683.                         else {
  684.                                 echo "#666666";
  685.                         }
  686.         ?>;
  687.         margin: 0px 0px 10px 10px;
  688.         padding: 0px;
  689.         text-align: left;
  690.         font-family: <?php
  691.                                 if (file_exists("data/fonts/body.txt")) {
  692.                                         $font_body = file_get_contents("data/fonts/body.txt");
  693.                                         echo "{$font_body},";
  694.                                 }
  695.         ?> arial, helvetica, sans-serif;
  696.         background-color: <?php
  697.                                 if (file_exists("data/colors/bg.txt")) {
  698.                                         $background_color = file_get_contents("data/colors/bg.txt");
  699.                                         if ($background_color == "transparent") {
  700.                                                 echo "#ffffff";
  701.                                         }
  702.                                         else {
  703.                                                 echo $background_color;
  704.                                         }
  705.                                 }
  706.                                 else {
  707.                                         echo "#ffffff";
  708.                                 }
  709.         ?>;
  710.  
  711.         <?php
  712.         if (file_exists("images/background.gif") and !file_exists("images/background.jpg") and !file_exists("images/background.png")) { ?>
  713.                 background-image: url('images/background.gif');
  714.                 background-attachment: <?php if (file_exists("data/bg-scroll.txt")) { echo scroll; } else { echo fixed; } ?>;
  715.                 background-repeat: <?php if (file_exists("data/bg-repeat.txt")) { readfile("data/bg-repeat.txt"); } else { echo repeat; } ?>;
  716.                 background-position: <?php if (file_exists("data/bg-position.txt")) { readfile("data/bg-position.txt"); } else { echo "top left"; } ?>;
  717.         <?php
  718.         }
  719.         if (!file_exists("images/background.gif") and file_exists("images/background.jpg") and !file_exists("images/background.png")) { ?>
  720.                 background-image: url('images/background.jpg');
  721.                 background-attachment: <?php if (file_exists("data/bg-scroll.txt")) { echo scroll; } else { echo fixed; } ?>;
  722.                 background-repeat: <?php if (file_exists("data/bg-repeat.txt")) { readfile("data/bg-repeat.txt"); } else { echo repeat; } ?>;
  723.                 background-position: <?php if (file_exists("data/bg-position.txt")) { readfile("data/bg-position.txt"); } else { echo "top left"; } ?>;
  724.         <?php
  725.         }
  726.         if (!file_exists("images/background.gif") and !file_exists("images/background.jpg") and file_exists("images/background.png")) { ?>
  727.                 background-image: url('images/background.png');
  728.                 background-attachment: <?php if (file_exists("data/bg-scroll.txt")) { echo scroll; } else { echo fixed; } ?>;
  729.                 background-repeat: <?php if (file_exists("data/bg-repeat.txt")) { readfile("data/bg-repeat.txt"); } else { echo repeat; } ?>;
  730.                 background-position: <?php if (file_exists("data/bg-position.txt")) { readfile("data/bg-position.txt"); } else { echo "top left"; } ?>;
  731.         <?php
  732.         }
  733.         ?>
  734. }
  735.  
  736. p, td {
  737.         font-size: 11px;
  738. }
  739.  
  740. a {
  741.         font-weight: bold;
  742.         text-decoration: none;
  743. }
  744.  
  745. a:link {
  746.         color: <?php
  747.                         if (file_exists("data/colors/link.txt")) {
  748.                                 $a_link_color = file_get_contents("data/colors/link.txt");
  749.                                 echo $a_link_color;
  750.                         }
  751.                         else {
  752.                                 echo "#666666";
  753.                         }
  754.         ?>;
  755. }
  756.  
  757. a:visited {
  758.         color: <?php
  759.                         if (file_exists("data/colors/vlink.txt")) {
  760.                                 $a_visited_color = file_get_contents("data/colors/vlink.txt");
  761.                                 echo $a_visited_color;
  762.                         }
  763.                         else {
  764.                                 echo "#666666";
  765.                         }
  766.         ?>;
  767. }
  768.  
  769. a:hover {
  770.         color: <?php
  771.                         if (file_exists("data/colors/hover.txt")) {
  772.                                 $a_hover_color = file_get_contents("data/colors/hover.txt");
  773.                                 echo $a_hover_color;
  774.                         }
  775.                         else {
  776.                                 echo "#336699";
  777.                         }
  778.         ?>;
  779. }
  780.  
  781. a:active {
  782.         color: <?php
  783.                         if (file_exists("data/colors/hover.txt")) {
  784.                                 $a_active_color = file_get_contents("data/colors/hover.txt");
  785.                                 echo $a_active_color;
  786.                         }
  787.                         else {
  788.                                 echo "#336699";
  789.                         }
  790.         ?>;
  791. }
  792.  
  793. a.navlink:link, a.navlink:visited, a.navlink:active, a.navlink:hover {
  794.         font-weight: normal;
  795.         text-decoration: none;
  796. }
  797.  
  798. #panel_title {
  799.         font-family: <?php
  800.                                 if (file_exists("data/fonts/panel-title.txt")) {
  801.                                         $font_panel_title = file_get_contents("data/fonts/panel-title.txt");
  802.                                         echo "{$font_panel_title},";
  803.                                 }
  804.         ?> arial, helvetica, sans-serif;
  805.         font-size: 12px;
  806.         font-weight: bold;
  807.         color: <?php
  808.                         if (file_exists("data/colors/pt-font.txt")) {
  809.                                 $panel_title_font_color = file_get_contents("data/colors/pt-font.txt");
  810.                                 echo $panel_title_font_color;
  811.                         }
  812.                         else {
  813.                                 echo "#666666";
  814.                         }
  815.         ?>;
  816.         padding: 5px 5px 5px 5px;
  817.         background-color: <?php
  818.                                 if (file_exists("data/colors/pt-bg.txt")) {
  819.                                         $panel_title_background_color = file_get_contents("data/colors/pt-bg.txt");
  820.                                         echo $panel_title_background_color;
  821.                                 }
  822.                                 else {
  823.                                         echo "transparent";
  824.                                 }
  825.         ?>;
  826.         margin: 0px 0px 0px 0px;
  827.         border-color: <?php
  828.                                 if (file_exists("data/colors/border.txt")) {
  829.                                         $panel_title_border_color = file_get_contents("data/colors/border.txt");
  830.                                         echo $panel_title_border_color;
  831.                                 }
  832.                                 else {
  833.                                         echo "#cccccc";
  834.                                 }
  835.         ?>;
  836.         border-width: 1px 1px 0px 1px;
  837.         border-style: solid solid none solid;
  838. }
  839.  
  840. #panel_body {
  841.         font-family: <?php
  842.                                 if (file_exists("data/fonts/panel-body.txt")) {
  843.                                         $font_panel_body = file_get_contents("data/fonts/panel-body.txt");
  844.                                         echo "{$font_panel_body},";
  845.                                 }
  846.         ?> arial, helvetica, sans-serif;
  847.         font-size: 11px;
  848.         color: <?php
  849.                         if (file_exists("data/colors/pb-font.txt")) {
  850.                                 $panel_body_font_color = file_get_contents("data/colors/pb-font.txt");
  851.                                 echo $panel_body_font_color;
  852.                         }
  853.                         else {
  854.                                 echo "#666666";
  855.                         }
  856.         ?>;
  857.  
  858.         <?php
  859.                 if (file_exists("data/round.txt")) {
  860.                         echo 'padding: 5px 5px 2px 5px;';
  861.                 }
  862.                 else {
  863.                         echo 'padding: 5px 5px 5px 5px;';
  864.                 }
  865.         ?>
  866.         background-color: <?php
  867.                                 if (file_exists("data/colors/pb-bg.txt")) {
  868.                                         $panel_body_background_color = file_get_contents("data/colors/pb-bg.txt");
  869.                                         echo $panel_body_background_color;
  870.                                 }
  871.                                 else {
  872.                                         echo "transparent";
  873.                                 }
  874.         ?>;
  875.  
  876.         <?php
  877.                 if (file_exists("data/round.txt")) {
  878.                         echo 'margin: 0px 0px 0px 0px;';
  879.                 }
  880.                 else {
  881.                         echo 'margin: 0px 0px 10px 0px;';
  882.                 }
  883.         ?>
  884.  
  885.         border-color: <?php
  886.                         if (file_exists("data/colors/border.txt")) {
  887.                                 $panel_body_border_color = file_get_contents("data/colors/border.txt");
  888.                                 echo $panel_body_border_color;
  889.                         }
  890.                         else {
  891.                                 echo "#cccccc";
  892.                         }
  893.         ?>;
  894.         <?php
  895.                 if (file_exists("data/round.txt")) {
  896.                         echo 'border-width: 1px 1px 0px 1px;';
  897.                         echo 'border-style: solid solid none solid;';
  898.                 }
  899.                 else {
  900.                         echo 'border-width: 1px 1px 1px 1px;';
  901.                         echo 'border-style: solid solid solid solid;';
  902.                 }
  903.         ?>
  904. }
  905.  
  906. #panel_footer {
  907.         font-family: <?php
  908.                                 if (file_exists("data/fonts/panel-footer.txt")) {
  909.                                         $font_panel_footer = file_get_contents("data/fonts/panel-footer.txt");
  910.                                         echo "{$font_panel_footer},";
  911.                                 }
  912.         ?> arial, helvetica, sans-serif;
  913.         font-size: 11px;
  914.         color: <?php
  915.                         if (file_exists("data/colors/pf-font.txt")) {
  916.                                 $panel_footer_font_color = file_get_contents("data/colors/pf-font.txt");
  917.                                 echo $panel_footer_font_color;
  918.                         }
  919.                         else {
  920.                                 echo "#666666";
  921.                         }
  922.         ?>;
  923.         <?php
  924.                 if (file_exists("data/round.txt")) {
  925.                         echo 'padding: 5px 5px 2px 5px;';
  926.                 }
  927.                 else {
  928.                         echo 'padding: 5px 5px 5px 5px;';
  929.                 }
  930.         ?>
  931.         background-color: <?php
  932.                                 if (file_exists("data/colors/pf-bg.txt")) {
  933.                                         $panel_footer_background_color = file_get_contents("data/colors/pf-bg.txt");
  934.                                         echo $panel_footer_background_color;
  935.                                 }
  936.                                 else {
  937.                                         echo "transparent";
  938.                                 }
  939.         ?>;
  940.  
  941.         <?php
  942.                 if (file_exists("data/round.txt")) {
  943.                         echo 'margin: 0px 0px 0px 0px;';
  944.                 }
  945.                 else {
  946.                         echo 'margin: 0px 0px 10px 0px;';
  947.                 }
  948.         ?>
  949.  
  950.         border-color: <?php
  951.                                 if (file_exists("data/colors/border.txt")) {
  952.                                         $panel_footer_border_color = file_get_contents("data/colors/border.txt");
  953.                                         echo $panel_footer_border_color;
  954.                                 }
  955.                                 else {
  956.                                         echo "#cccccc";
  957.                                 }
  958.         ?>;
  959.         <?php
  960.                 if (file_exists("data/round.txt")) {
  961.                         echo 'border-width: 1px 1px 0px 1px;';
  962.                         echo 'border-style: solid solid none solid;';
  963.                 }
  964.                 else {
  965.                         echo 'border-width: 0px 1px 1px 1px;';
  966.                         echo 'border-style: none solid solid solid;';
  967.                 }
  968.         ?>
  969.         text-align: right;
  970. }
  971.  
  972. .input {        
  973.         color: <?php
  974.                         if (file_exists("data/colors/border.txt")) {
  975.                                 $input_color = file_get_contents("data/colors/border.txt");
  976.                                 echo $input_color;
  977.                         }
  978.                         else {
  979.                                 echo "#666666";
  980.                         }
  981.         ?>;
  982.         background: #ffffff;
  983.         border: <?php
  984.                         if (file_exists("data/colors/border.txt")) {
  985.                                 $panel_footer_border_color = file_get_contents("data/colors/border.txt");
  986.                                 echo $panel_footer_border_color;
  987.                         }
  988.                         else {
  989.                                 echo "#999999";
  990.                         }
  991.         ?> solid 1px;
  992.         width: 300px;
  993.         font-family: <?php
  994.                                 if (file_exists("data/fonts/input.txt")) {
  995.                                         $font_input = file_get_contents("data/fonts/input.txt");
  996.                                         echo "{$font_input},";
  997.                                 }
  998.         ?> arial, helvetica, sans-serif;
  999.         font-size: 11px;
  1000. }
  1001.  
  1002. .search {      
  1003.         color: #666666;
  1004.         background: #ffffff;
  1005.         width: 100%;
  1006.  
  1007.         font-family: <?php
  1008.                                 if (file_exists("data/fonts/input.txt")) {
  1009.                                         $font_input = file_get_contents("data/fonts/input.txt");
  1010.                                         echo "{$font_input},";
  1011.                                 }
  1012.         ?> arial, helvetica, sans-serif;
  1013.         font-size: 11px;
  1014. }
  1015.  
  1016. #panel_free {
  1017.         padding: 0px 5px 0px 5px;
  1018.         margin: 0px 0px 10px 0px;
  1019. }
  1020.  
  1021. .rbtop {
  1022.         display: block;
  1023.         background: transparent;
  1024.         font-size: 1px;
  1025.         margin: 0px 0px 0px 0px;
  1026. }
  1027.  
  1028. .rbbottom {
  1029.         display: block;
  1030.         background: transparent;
  1031.         font-size: 1px;
  1032.         margin: 0px 0px 10px 0px;
  1033. }
  1034.  
  1035. .rb1t, .rb2t, .rb3t, .rb4t, .rb1b, .rb2b, .rb3b, .rb4b, .rb1e, .rb2e, .rb3e, .rb4e {
  1036.         display: block;
  1037.         overflow: hidden;
  1038. }
  1039.  
  1040. .rb1t, .rb2t, .rb3t, .rb1b, .rb2b, .rb3b, .rb1e, .rb2e, .rb3e {
  1041.         height: 1px;
  1042. }
  1043.  
  1044. .rb2t, .rb3t, .rb4t {
  1045.         background-color: <?php
  1046.                                 if (file_exists("data/colors/pt-bg.txt")) {
  1047.                                         $panel_title_background_color = file_get_contents("data/colors/pt-bg.txt");
  1048.                                         echo $panel_title_background_color;
  1049.                                 }
  1050.                                 else {
  1051.                                         echo "transparent";
  1052.                                 }
  1053.         ?>;
  1054.         border-left: 1px solid;
  1055.         border-right: 1px solid;
  1056.         border-color: <?php
  1057.                         if (file_exists("data/colors/border.txt")) {
  1058.                                 $panel_title_border_color = file_get_contents("data/colors/border.txt");
  1059.                                 echo $panel_title_border_color;
  1060.                         }
  1061.                         else {
  1062.                                 echo "#cccccc";
  1063.                         };
  1064.         ?>;
  1065. }
  1066.  
  1067. .rb2b, .rb3b, .rb4b {
  1068.         background-color: <?php
  1069.                                 if (file_exists("data/colors/pb-bg.txt")) {
  1070.                                         $panel_title_background_color = file_get_contents("data/colors/pb-bg.txt");
  1071.                                         echo $panel_title_background_color;
  1072.                                 }
  1073.                                 else {
  1074.                                         echo "transparent";
  1075.                                 }
  1076.         ?>;
  1077.         border-left: 1px solid;
  1078.         border-right: 1px solid;
  1079.         border-color: <?php
  1080.                         if (file_exists("data/colors/border.txt")) {
  1081.                                 $panel_title_border_color = file_get_contents("data/colors/border.txt");
  1082.                                 echo $panel_title_border_color;
  1083.                         }
  1084.                         else {
  1085.                                 echo "#cccccc";
  1086.                         };
  1087.         ?>;
  1088. }
  1089.  
  1090. .rb2e, .rb3e, .rb4e {
  1091.         background-color: <?php
  1092.                                 if (file_exists("data/colors/pf-bg.txt")) {
  1093.                                         $panel_title_background_color = file_get_contents("data/colors/pf-bg.txt");
  1094.                                         echo $panel_title_background_color;
  1095.                                 }
  1096.                                 else {
  1097.                                         echo "transparent";
  1098.                                 }
  1099.         ?>;
  1100.         border-left: 1px solid;
  1101.         border-right: 1px solid;
  1102.         border-color: <?php
  1103.                         if (file_exists("data/colors/border.txt")) {
  1104.                                 $panel_title_border_color = file_get_contents("data/colors/border.txt");
  1105.                                 echo $panel_title_border_color;
  1106.                         }
  1107.                         else {
  1108.                                 echo "#cccccc";
  1109.                         };
  1110.         ?>;
  1111. }
  1112.  
  1113. .rb1t, .rb1b, .rb1e {
  1114.         margin: 0 5px;
  1115.         background: <?php
  1116.                         if (file_exists("data/colors/border.txt")) {
  1117.                                 $panel_title_border_color = file_get_contents("data/colors/border.txt");
  1118.                                 echo $panel_title_border_color;
  1119.                         }
  1120.                         else {
  1121.                                 echo "#cccccc";
  1122.                         };
  1123.         ?>;
  1124. }
  1125.  
  1126. .rb2t, .rb2b, .rb2e {
  1127.         margin: 0 3px;
  1128.         border-width: 0 2px;
  1129. }
  1130.  
  1131. .rb3t, .rb3b, .rb3e {
  1132.         margin: 0 2px;
  1133. }
  1134.  
  1135. .rb4t, .rb4b, .rb4e {
  1136.         height: 2px;
  1137.         margin: 0 1px;
  1138. }
  1139.  
  1140. .xtitle {
  1141.         display: block;
  1142.         border:0 solid;
  1143.         border-width:0 1px;
  1144.         padding: 1px 5px 5px 5px;
  1145.         font-weight: bold;
  1146.         font-family: <?php
  1147.                                 if (file_exists("data/fonts/panel-title.txt")) {
  1148.                                         $font_panel_title = file_get_contents("data/fonts/panel-title.txt");
  1149.                                         echo "{$font_panel_title},";
  1150.                                 }
  1151.         ?> arial, helvetica, sans-serif;
  1152.         color: <?php
  1153.                         if (file_exists("data/colors/pt-font.txt")) {
  1154.                                 $panel_title_font_color = file_get_contents("data/colors/pt-font.txt");
  1155.                                 echo $panel_title_font_color;
  1156.                         }
  1157.                         else {
  1158.                                 echo "#666666";
  1159.                         }
  1160.         ?>;
  1161.         background-color: <?php
  1162.                                 if (file_exists("data/colors/pt-bg.txt")) {
  1163.                                         $panel_title_background_color = file_get_contents("data/colors/pt-bg.txt");
  1164.                                         echo $panel_title_background_color;
  1165.                                 }
  1166.                                 else {
  1167.                                         echo "transparent";
  1168.                                 }
  1169.         ?>;
  1170.         border-color: <?php
  1171.                         if (file_exists("data/colors/border.txt")) {
  1172.                                 $panel_title_border_color = file_get_contents("data/colors/border.txt");
  1173.                                 echo $panel_title_border_color;
  1174.                         }
  1175.                         else {
  1176.                                 echo "#cccccc";
  1177.                         };
  1178.         ?>;
  1179. }
  1180.  
  1181. .rbspace {
  1182.         height: 3px;
  1183. }
  1184.  
  1185. #panel_entry_body {
  1186.         font-family: <?php
  1187.                                 if (file_exists("data/fonts/panel-body.txt")) {
  1188.                                         $font_panel_body = file_get_contents("data/fonts/panel-body.txt");
  1189.                                         echo "{$font_panel_body},";
  1190.                                 }
  1191.         ?> arial, helvetica, sans-serif;
  1192.         font-size: 11px;
  1193.         color: <?php
  1194.                         if (file_exists("data/colors/pb-font.txt")) {
  1195.                                 $panel_body_font_color = file_get_contents("data/colors/pb-font.txt");
  1196.                                 echo $panel_body_font_color;
  1197.                         }
  1198.                         else {
  1199.                                 echo "#666666";
  1200.                         }
  1201.         ?>;
  1202.         <?php
  1203.                 if (file_exists("data/round.txt")) {
  1204.                         echo 'padding: 5px 5px 2px 5px;';
  1205.                 }
  1206.                 else {
  1207.                         echo 'padding: 5px 5px 5px 5px;';
  1208.                 }
  1209.         ?>
  1210.         background-color: <?php
  1211.                                 if (file_exists("data/colors/pb-bg.txt")) {
  1212.                                         $panel_body_background_color = file_get_contents("data/colors/pb-bg.txt");
  1213.                                         echo $panel_body_background_color;
  1214.                                 }
  1215.                                 else {
  1216.                                         echo "transparent";
  1217.                                 }
  1218.         ?>;
  1219.         margin: 0px 0px 0px 0px;
  1220.         border-color: <?php
  1221.                         if (file_exists("data/colors/border.txt")) {
  1222.                                 $panel_body_border_color = file_get_contents("data/colors/border.txt");
  1223.                                 echo $panel_body_border_color;
  1224.                         }
  1225.                         else {
  1226.                                 echo "#cccccc";
  1227.                         }
  1228.         ?>;
  1229.         <?php
  1230.                 if (file_exists("data/round.txt")) {
  1231.                         echo 'border-width: 1px 1px 0px 1px;';
  1232.                         echo 'border-style: solid solid none solid;';
  1233.                 }
  1234.                 else {
  1235.                         echo 'border-width: 1px 1px 1px 1px;';
  1236.                         echo 'border-style: solid solid solid solid;';
  1237.                 }
  1238.         ?>
  1239. }
  1240. </style>
  1241.  
  1242. <link rel="alternate" type="application/rss+xml" title="RSS 0.91" href="rss.php?ver=0.91">
  1243. <link rel="alternate" type="application/rss+xml" title="RSS 1.0" href="rss.php?ver=1.0">
  1244. <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss.php?ver=2.0">
  1245.  
  1246. <?php
  1247.  
  1248. if (file_exists("data/center.txt")) {
  1249.         echo "<center>";
  1250. }
  1251.  
  1252. if (file_exists("header.php")) {
  1253.         include("header.php");
  1254. }
  1255. ?>
  1256.  
  1257. <table border=0 cellspacing=10 cellpadding=0>
  1258. <tr><td width=175 valign=top>
  1259.  
  1260. <?php
  1261.  
  1262. if (file_exists("data/round.txt")) {
  1263.         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1264. }
  1265. else {
  1266.         echo '<div id=panel_title>';
  1267. }
  1268.  
  1269. ?>
  1270.  
  1271. Profile</div>
  1272. <div id="panel_body">
  1273. <?php
  1274. if (file_exists("images/profile.gif")) {
  1275.         $profile_gif_image_size = getimagesize("images/profile.gif");
  1276.         $profile_gif_image_width = $profile_gif_image_size[0];
  1277.         $profile_gif_image_height = $profile_gif_image_size[1];
  1278.  
  1279.         $max_profile_gif_image_width = 163;
  1280.  
  1281.         if ($profile_gif_image_width > $max_profile_gif_image_width) {  
  1282.                 $sizefactor = (double) ($max_profile_gif_image_width / $profile_gif_image_width) ;
  1283.                 $profile_gif_image_width = (int) ($profile_gif_image_width * $sizefactor);
  1284.                 $profile_gif_image_height = (int) ($profile_gif_image_height * $sizefactor);
  1285.         }
  1286.  
  1287.         echo "<img src=images/profile.gif border=0 width=";
  1288.         echo $profile_gif_image_width;
  1289.         echo " height=";
  1290.         echo $profile_gif_image_height;
  1291.         echo " align=left>";
  1292. }
  1293. if (file_exists("images/profile.jpg")) {
  1294.         $profile_jpg_image_size = getimagesize("images/profile.jpg");
  1295.         $profile_jpg_image_width = $profile_jpg_image_size[0];
  1296.         $profile_jpg_image_height = $profile_jpg_image_size[1];
  1297.  
  1298.         $max_profile_jpg_image_width = 163;
  1299.  
  1300.         if ($profile_jpg_image_width > $max_profile_jpg_image_width) {  
  1301.                 $sizefactor = (double) ($max_profile_jpg_image_width / $profile_jpg_image_width) ;
  1302.                 $profile_jpg_image_width = (int) ($profile_jpg_image_width * $sizefactor);
  1303.                 $profile_jpg_image_height = (int) ($profile_jpg_image_height * $sizefactor);
  1304.         }
  1305.  
  1306.         echo "<img src=images/profile.jpg border=0 width=";
  1307.         echo $profile_jpg_image_width;
  1308.         echo " height=";
  1309.         echo $profile_jpg_image_height;
  1310.         echo " align=left>";
  1311. }
  1312. if (file_exists("images/profile.png")) {
  1313.         $profile_png_image_size = getimagesize("images/profile.png");
  1314.         $profile_png_image_width = $profile_png_image_size[0];
  1315.         $profile_png_image_height = $profile_png_image_size[1];
  1316.  
  1317.         $max_profile_png_image_width = 163;
  1318.  
  1319.         if ($profile_png_image_width > $max_profile_png_image_width) {  
  1320.                 $sizefactor = (double) ($max_profile_png_image_width / $profile_png_image_width) ;
  1321.                 $profile_png_image_width = (int) ($profile_png_image_width * $sizefactor);
  1322.                 $profile_png_image_height = (int) ($profile_png_image_height * $sizefactor);
  1323.         }
  1324.  
  1325.         echo "<img src=images/profile.png border=0 width=";
  1326.         echo $profile_png_image_width;
  1327.         echo " height=";
  1328.         echo $profile_png_image_height;
  1329.         echo " align=left>";
  1330. }
  1331. include("data/profile.php");
  1332. ?>
  1333. </div>
  1334.  
  1335. <?php
  1336.         if (file_exists("data/round.txt")) {
  1337.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1338.         }
  1339. ?>
  1340.  
  1341. <?php
  1342.  
  1343. if (file_exists("data/round.txt")) {
  1344.         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1345. }
  1346. else {
  1347.         echo '<div id=panel_title>';
  1348. }
  1349.  
  1350. ?>
  1351.  
  1352. Navigation</div>
  1353. <div id=panel_body>
  1354. <a class=navlink href="<?php echo $_SERVER['PHP_SELF']; ?>">Home</a><br>
  1355.  
  1356. <?php
  1357.  
  1358. if (file_exists("data/bb.txt") and file_exists("data/members/active")) {
  1359.         echo '<a class=navlink href=member.php?id=all>Members</a><br>';
  1360. }
  1361.  
  1362. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1363.         echo '<a class=navlink href=add.php>Add Entry</a><br>';
  1364.         echo '<a class=navlink href=settings.php>Settings</a><br>';
  1365.         echo '<a class=navlink href=panels.php>Panels</a><br>';
  1366.         echo '<a class=navlink href=cat.php>Categories</a><br>';
  1367.         echo '<a class=navlink href=colors.php>Colors</a><br>';
  1368.         echo '<a class=navlink href=fonts.php>Fonts</a><br>';
  1369.         echo '<a class=navlink href=login.php>Logout</a>';
  1370. } elseif (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != $login_username) and file_exists("data/members/active/{$_SESSION['logged_in']}") and file_exists("data/bb.txt")) {
  1371.  
  1372.         if (file_exists("data/members/active/{$_SESSION['logged_in']}/category.txt")) {
  1373.                 $bb_cat = file_get_contents("data/members/active/{$_SESSION['logged_in']}/category.txt");
  1374.                 if (!file_exists("data/categories/$bb_cat") or ($bb_cat == "")) {
  1375.                         unlink("data/members/active/{$_SESSION['logged_in']}/category.txt");
  1376.                 }
  1377.         }
  1378.  
  1379.         if (file_exists("data/members/active/{$_SESSION['logged_in']}/rw.txt") or file_exists("data/members/active/{$_SESSION['logged_in']}/category.txt")) {
  1380.                 echo '<a class=navlink href=add.php>Add Entry</a><br>';
  1381.         }
  1382.         echo '<a class=navlink href=options.php>Options</a><br>';
  1383.         echo '<a class=navlink href=login.php>Logout</a>';
  1384. }
  1385. else {
  1386.         if (file_exists("data/bb.txt") and file_exists("data/reg.txt")) {
  1387.                 echo '<a class=navlink href=reg.php>Register</a><br>';
  1388.         }
  1389.         echo '<a class=navlink href=login.php>Login</a>';
  1390. }
  1391. ?>
  1392.  
  1393. </div>
  1394.  
  1395. <?php
  1396.         if (file_exists("data/round.txt")) {
  1397.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1398.         }
  1399. ?>
  1400.  
  1401. <?php
  1402. if (file_exists("data/sticky")) {
  1403.  
  1404.         if ($dh_sticky_list = opendir("data/sticky")) {
  1405.  
  1406.                 while (($entry_sticky_list = readdir($dh_sticky_list)) !== false) {
  1407.  
  1408.                         if (file_exists("data/items/$entry_sticky_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1409.                                 continue;
  1410.                         }
  1411.  
  1412.                         if (file_exists("data/items/$entry_sticky_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  1413.                                 continue;
  1414.                         }
  1415.  
  1416.                         $get_cat_dir = file_get_contents("data/items/$entry_sticky_list/category.txt");
  1417.  
  1418.                         if (file_exists("data/categories/$get_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_sticky_list/cat.txt")) {
  1419.                                 continue;
  1420.                         }
  1421.  
  1422.                         if ($entry_sticky_list != "." && $entry_sticky_list != ".." && fnmatch("*", $entry_sticky_list)) {
  1423.                                 $show_sticky_list[] = $entry_sticky_list;
  1424.                         }
  1425.                 }
  1426.                 closedir($dh_sticky_list);
  1427.         }
  1428.  
  1429.         sort($show_sticky_list);
  1430.         reset($show_sticky_list);
  1431.         $count_sticky_list = count($show_sticky_list);
  1432.        
  1433.         if ($count_sticky_list > 0) {
  1434.  
  1435.                 if (file_exists("data/round.txt")) {
  1436.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1437.                 }
  1438.                 else {
  1439.                         echo '<div id=panel_title>';
  1440.                 }
  1441.                
  1442.                 echo 'Quick Links</div>';
  1443.                 echo '<div id=panel_body>';
  1444.                 foreach ($show_sticky_list as $sticky_list_entry) {
  1445.                         echo '<a class=navlink href=' . $_SERVER['PHP_SELF'] . '?entry=';
  1446.                         echo $sticky_list_entry;
  1447.                         echo '>';
  1448.                         readfile("data/items/$sticky_list_entry/title.txt");
  1449.                         echo '</a><br>';
  1450.                 }
  1451.                 echo '</div>';
  1452.  
  1453.                 if (file_exists("data/round.txt")) {
  1454.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1455.                 }
  1456.         }
  1457. }
  1458. ?>
  1459.  
  1460.  
  1461.  
  1462. <?php
  1463. if (file_exists("data/panels")) {
  1464.         if ($dh_panel_list = opendir("data/panels")) {
  1465.                 while (($entry_panel_list = readdir($dh_panel_list)) !== false) {
  1466.  
  1467.                         if (file_exists("data/panels/$entry_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1468.                                 continue;
  1469.                         }
  1470.  
  1471.                         if (file_exists("data/panels/$entry_panel_list/right.txt")) {
  1472.                                 continue;
  1473.                         }
  1474.  
  1475.                         if (file_exists("data/panels/$entry_panel_list/center.txt")) {
  1476.                                 continue;
  1477.                         }
  1478.  
  1479.                         if (file_exists("data/panels/$entry_panel_list/top.txt")) {
  1480.                                 continue;
  1481.                         }
  1482.  
  1483.                         if (file_exists("data/panels/$entry_panel_list/entry.txt")) {
  1484.                                 continue;
  1485.                         }
  1486.  
  1487.                         if ($entry_panel_list != "." && $entry_panel_list != ".." && fnmatch("*", $entry_panel_list)) {
  1488.                                 $show_panel_list[] = $entry_panel_list;
  1489.                         }
  1490.                 }
  1491.                 closedir($dh_panel_list);
  1492.         }
  1493.  
  1494.         sort($show_panel_list);
  1495.         reset($show_panel_list);
  1496.         $count_panel_list = count($show_panel_list);
  1497.        
  1498.         if ($count_panel_list > 0) {
  1499.                 foreach ($show_panel_list as $panel_list_entry) {
  1500.                         if (!file_exists("data/panels/$panel_list_entry/free.txt")) {
  1501.  
  1502.                                 if (file_exists("data/round.txt")) {
  1503.                                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1504.                                 }
  1505.                                 else {
  1506.                                         echo '<div id=panel_title>';
  1507.                                 }
  1508.  
  1509.                                 readfile("data/panels/$panel_list_entry/title.txt");
  1510.  
  1511.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1512.                                         echo "<a href=panels.php#{$panel_list_entry}>";
  1513.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  1514.                                 }
  1515.  
  1516.                                 if (file_exists("data/panels/$panel_list_entry/private.txt")) {
  1517.                                         echo '<img src=images/widget.private.png border=0 width=11 height=11 align=right>';
  1518.                                 }
  1519.  
  1520.                                 echo '</div><div id=panel_body>';
  1521.                         }
  1522.  
  1523.                         if (file_exists("data/panels/$panel_list_entry/free.txt")) {
  1524.                                 echo '<div id=panel_free>';
  1525.                         }
  1526.  
  1527.                         include("data/panels/$panel_list_entry/panel.php");
  1528.  
  1529.                         echo '</div>';
  1530.  
  1531.                         if (file_exists("data/round.txt") and !file_exists("data/panels/$panel_list_entry/free.txt")) {
  1532.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1533.                         }
  1534.                 }
  1535.         }
  1536. }
  1537. ?>
  1538.  
  1539. </td>
  1540.  
  1541. <td valign=top width=<?php if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) { echo "610"; } else { echo "525"; } ?>>
  1542.  
  1543. <?php
  1544. if (file_exists("data/panels")) {
  1545.         if ($dh_top_panel_list = opendir("data/panels")) {
  1546.                 while (($entry_top_panel_list = readdir($dh_top_panel_list)) !== false) {
  1547.  
  1548.                         if (file_exists("data/panels/$entry_top_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1549.                                 continue;
  1550.                         }
  1551.  
  1552.                         if (!file_exists("data/panels/$entry_top_panel_list/top.txt")) {
  1553.                                 continue;
  1554.                         }
  1555.  
  1556.                         if ($entry_top_panel_list != "." && $entry_top_panel_list != ".." && fnmatch("*", $entry_top_panel_list)) {
  1557.                                 $show_top_panel_list[] = $entry_top_panel_list;
  1558.                         }
  1559.                 }
  1560.                 closedir($dh_top_panel_list);
  1561.         }
  1562.  
  1563.         sort($show_top_panel_list);
  1564.         reset($show_top_panel_list);
  1565.         $count_top_panel_list = count($show_top_panel_list);
  1566.        
  1567.         if ($count_top_panel_list > 0) {
  1568.                 foreach ($show_top_panel_list as $top_panel_list_entry) {
  1569.                         if (!file_exists("data/panels/$top_panel_list_entry/free.txt")) {
  1570.  
  1571.                                 if (file_exists("data/round.txt")) {
  1572.                                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1573.                                 }
  1574.                                 else {
  1575.                                         echo '<div id=panel_title>';
  1576.                                 }
  1577.  
  1578.                                 readfile("data/panels/$top_panel_list_entry/title.txt");
  1579.  
  1580.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1581.                                         echo "<a href=panels.php#{$top_panel_list_entry}>";
  1582.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  1583.                                 }
  1584.  
  1585.                                 echo '</div><div id=panel_body>';
  1586.                         }
  1587.  
  1588.                         if (file_exists("data/panels/$top_panel_list_entry/free.txt")) {
  1589.                                 echo '<div id=panel_free>';
  1590.                         }
  1591.  
  1592.                         include("data/panels/$top_panel_list_entry/panel.php");
  1593.                         echo '</div>';
  1594.  
  1595.                         if (file_exists("data/round.txt") and !file_exists("data/panels/$top_panel_list_entry/free.txt")) {
  1596.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1597.                         }
  1598.                 }
  1599.         }
  1600. }
  1601. ?>
  1602.  
  1603. <?php
  1604.  
  1605. if (file_exists("data/bb.txt") and file_exists("data/bb-summary.txt") and !file_exists("data/lite.txt") and !isset($_REQUEST['entry']) and !isset($_REQUEST['category']) and !isset($_REQUEST['start']) and !isset($_REQUEST['author']) and !isset($_REQUEST['archive']) and !isset($_REQUEST['find'])) {
  1606.  
  1607. if ($dh_latest_post_items = opendir($dir)) {
  1608.         while (($entry_latest_post_items = readdir($dh_latest_post_items)) !== false) {
  1609.  
  1610.                 if (file_exists("data/items/$entry_latest_post_items/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1611.                         continue;
  1612.                 }
  1613.  
  1614.                 // hide_member (20070606)
  1615.                 //if (file_exists("data/items/$entry_latest_post_items/member.txt") and (!isset($_SESSION['logged_in']))) {
  1616.                 //      continue;
  1617.                 //}
  1618.  
  1619.                 $cat_dir = file_get_contents("data/items/$entry_latest_post_items/category.txt");
  1620.  
  1621.                 if (file_exists("data/categories/$cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_latest_post_items/cat.txt")) {
  1622.                         continue;
  1623.                 }
  1624.  
  1625.                 if ($entry_latest_post_items != "." && $entry_latest_post_items != ".." && fnmatch("*", $entry_latest_post_items)) {
  1626.                         $show_latest_post_items[] = $entry_latest_post_items;
  1627.                 }
  1628.         }
  1629.         closedir($dh_latest_post_items);
  1630. }
  1631.  
  1632. rsort($show_latest_post_items);
  1633. reset($show_latest_post_items);
  1634. $count_latest_post_items = count($show_latest_post_items);
  1635.  
  1636. if ($count_latest_post_items > 0) {
  1637.  
  1638.         if (file_exists("data/round.txt")) {
  1639.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1640.         }
  1641.         else {
  1642.                 echo '<div id=panel_title>';
  1643.         }
  1644.  
  1645.         echo "Latest Entries</div><div id=panel_body>";
  1646.         echo "<table border=0 cellspacing=1 cellpadding=2 bgcolor=#cccccc width=100%>";
  1647.         echo "<tr><td bgcolor=#eeeeee align=center><p>topic</p></td><td bgcolor=#eeeeee align=center><p>author</p></td><td bgcolor=#eeeeee align=center><p>views</p></td><td bgcolor=#eeeeee align=center><p>comments</p></td><td bgcolor=#eeeeee align=center><p>last post</p></td></tr>";
  1648.  
  1649.         $increment_latest_post_entries = 0;
  1650.         $show_latest_post_entries = 5;
  1651.  
  1652.         while ($increment_latest_post_entries <= $show_latest_post_entries) {
  1653.                 echo '<tr><td bgcolor=#ffffff><a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $show_latest_post_items[$increment_latest_post_entries];
  1654.  
  1655.                 if ($dh_summary_comments = opendir("$dir/$show_latest_post_items[$increment_latest_post_entries]/comments/live")) {
  1656.                         while (($entry_summary_comments = readdir($dh_summary_comments)) !== false) {
  1657.                                 if ($entry_summary_comments != "." && $entry_summary_comments != ".." && fnmatch("*", $entry_summary_comments)) {
  1658.                                         $items_summary_comments[] = $entry_summary_comments;
  1659.                                 }
  1660.                         }
  1661.                 closedir($dh_summary_comments);
  1662.                 }
  1663.                 rsort($items_summary_comments);
  1664.                 $summary_comments = count($items_summary_comments);
  1665.  
  1666.                 if ($summary_comments > 0) {
  1667.                         echo '&show=comments';
  1668.                 }
  1669.  
  1670.                 echo '>';
  1671.                 readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/title.txt");
  1672.                 echo '</a></td>';
  1673.                 echo '<td bgcolor=#ffffff><a href=member.php?id=';
  1674.                 readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/author.txt");
  1675.                 echo '>';
  1676.                 readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/author.txt");
  1677.                 echo '</a></td>';
  1678.                 echo '<td bgcolor=#ffffff align=right>';
  1679.                 if (!file_exists("$dir/$show_latest_post_items[$increment_latest_post_entries]/views.txt")) {
  1680.                         echo 0;
  1681.                 }
  1682.                 else {
  1683.                         readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/views.txt");
  1684.                 }
  1685.                 echo '</td>';
  1686.  
  1687.                 if ($summary_comments < 1) {
  1688.                         echo "<td bgcolor=#ffffff align=right><p>0</p></td>";
  1689.                         echo "<td bgcolor=#ffffff align=right><p>";
  1690.                         $iso_year = substr($show_latest_post_items[$increment_latest_post_entries],0,4);
  1691.                         $iso_month = substr($show_latest_post_items[$increment_latest_post_entries],4,2);
  1692.                         $iso_day = substr($show_latest_post_items[$increment_latest_post_entries],6,2);
  1693.                         $iso_last = $iso_year . "-" . $iso_month . "-" . $iso_day;
  1694.                         echo $iso_last;
  1695.                         echo "</p></td>";
  1696.                 }
  1697.                 else {
  1698.                         echo "<td bgcolor=#ffffff align=right><p>$summary_comments</p></td>";
  1699.                         echo "<td bgcolor=#ffffff align=right><p>";
  1700.                         $iso_year = substr($items_summary_comments[0],0,4);
  1701.                         $iso_month = substr($items_summary_comments[0],4,2);
  1702.                         $iso_day = substr($items_summary_comments[0],6,2);
  1703.                         $iso_last = $iso_year . "-" . $iso_month . "-" . $iso_day;
  1704.                         echo $iso_last;
  1705.                         echo "</p></td>";
  1706.                 }
  1707.                 unset($items_summary_comments);
  1708.  
  1709.                 $increment_latest_post_entries = $increment_latest_post_entries + 1;
  1710.         }
  1711. }
  1712.  
  1713. if ($count_latest_post_items > 0) {
  1714.         echo "</table></div>";
  1715.  
  1716.         if (file_exists("data/round.txt")) {
  1717.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1718.         }
  1719. }
  1720.  
  1721. }
  1722.  
  1723. ?>
  1724.  
  1725. <?php
  1726. if (file_exists("data/panels")) {
  1727.         if ($dh_center_panel_list = opendir("data/panels")) {
  1728.                 while (($entry_center_panel_list = readdir($dh_center_panel_list)) !== false) {
  1729.  
  1730.                         if (file_exists("data/panels/$entry_center_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1731.                                 continue;
  1732.                         }
  1733.  
  1734.                         if (!file_exists("data/panels/$entry_center_panel_list/center.txt")) {
  1735.                                 continue;
  1736.                         }
  1737.  
  1738.                         if ($entry_center_panel_list != "." && $entry_center_panel_list != ".." && fnmatch("*", $entry_center_panel_list)) {
  1739.                                 $show_center_panel_list[] = $entry_center_panel_list;
  1740.                         }
  1741.                 }
  1742.                 closedir($dh_center_panel_list);
  1743.         }
  1744.  
  1745.         sort($show_center_panel_list);
  1746.         reset($show_center_panel_list);
  1747.         $count_center_panel_list = count($show_center_panel_list);
  1748.        
  1749.         if ($count_center_panel_list > 0) {
  1750.                 foreach ($show_center_panel_list as $center_panel_list_entry) {
  1751.                         if (!file_exists("data/panels/$center_panel_list_entry/free.txt")) {
  1752.  
  1753.                                 if (file_exists("data/round.txt")) {
  1754.                                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1755.                                 }
  1756.                                 else {
  1757.                                         echo '<div id=panel_title>';
  1758.                                 }
  1759.  
  1760.                                 readfile("data/panels/$center_panel_list_entry/title.txt");
  1761.  
  1762.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1763.                                         echo "<a href=panels.php#{$center_panel_list_entry}>";
  1764.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  1765.                                 }
  1766.  
  1767.                                 echo '</div><div id=panel_body>';
  1768.                         }
  1769.  
  1770.                         if (file_exists("data/panels/$center_panel_list_entry/free.txt")) {
  1771.                                 echo '<div id=panel_free>';
  1772.                         }
  1773.  
  1774.                         include("data/panels/$center_panel_list_entry/panel.php");
  1775.                         echo '</div>';
  1776.  
  1777.                         if (file_exists("data/round.txt") and !file_exists("data/panels/$center_panel_list_entry/free.txt")) {
  1778.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  1779.                         }
  1780.                 }
  1781.         }
  1782. }
  1783. ?>
  1784.  
  1785. <?php
  1786.  
  1787. if (is_dir($dir)) {
  1788.         if ($dh = opendir($dir)) {
  1789.                 while (($entry_main = readdir($dh)) !== false) {
  1790.  
  1791.                         if (file_exists("data/items/$entry_main/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1792.                                 continue;
  1793.                         }
  1794.  
  1795.                         if (file_exists("data/items/$entry_main/member.txt") and (!isset($_SESSION['logged_in']))) {
  1796.                                 continue;
  1797.                         }
  1798.  
  1799.                         $cat_dir = file_get_contents("data/items/$entry_main/category.txt");
  1800.  
  1801.                         if (file_exists("data/categories/$cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_main/cat.txt")) {
  1802.                                 continue;
  1803.                         }
  1804.  
  1805.                         if (file_exists("data/nocat.txt") and file_exists("data/items/$entry_main/category.txt") and !file_exists("data/items/$entry_main/cat.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['category']) or empty($_REQUEST['category'])) and (!isset($_REQUEST['entry']) or empty($_REQUEST['entry'])) and (!isset($_REQUEST['author']) or empty($_REQUEST['author']))) {
  1806.                                 continue;
  1807.                         }
  1808.  
  1809.                         if ($entry_main != "." && $entry_main != ".." && fnmatch($filter, $entry_main)) {
  1810.                                 if (isset($_REQUEST['category']) and !empty($_REQUEST['category']) and file_exists(strip_tags(strtolower(str_replace(" ", "-", "data/categories/{$_REQUEST['category']}"))))) {
  1811.                                         $category = str_replace(" ", "-", $_REQUEST['category']);
  1812.                                         $category = strtolower($category);
  1813.                                         $category = strip_tags($category);
  1814.                                         if (file_exists("data/items/$entry_main/category.txt") and (file_get_contents("data/items/$entry_main/category.txt") == "$category")) {
  1815.                                                 $items[] = $entry_main;
  1816.                                         }
  1817.                                 }
  1818.                                 elseif (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and file_exists("data/members/active/{$_REQUEST['author']}") and file_exists("data/bb.txt")) {
  1819.                                         if (file_exists("data/items/$entry_main/author.txt") and (file_get_contents("data/items/$entry_main/author.txt") == $_REQUEST['author'])) {
  1820.                                                 $items[] = $entry_main;
  1821.                                         }
  1822.                                 }
  1823.                                 elseif (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and !file_exists("data/members/active/{$_REQUEST['author']}") and (file_get_contents("data/username.txt") == $_REQUEST['author']) and file_exists("data/bb.txt")) {
  1824.                                         if (file_exists("data/items/$entry_main/author.txt") and (file_get_contents("data/items/$entry_main/author.txt") == $_REQUEST['author'])) {
  1825.                                                 $items[] = $entry_main;
  1826.                                         }
  1827.                                 }
  1828.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "private")) {
  1829.                                         if (file_exists("data/items/$entry_main/private.txt")) {
  1830.                                                 $items[] = $entry_main;
  1831.                                         }
  1832.                                 }
  1833.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "member")) {
  1834.                                         if (file_exists("data/items/$entry_main/member.txt")) {
  1835.                                                 $items[] = $entry_main;
  1836.                                         }
  1837.                                 }
  1838.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "passwd")) {
  1839.                                         if (file_exists("data/items/$entry_main/passwd.txt")) {
  1840.                                                 $items[] = $entry_main;
  1841.                                         }
  1842.                                 }
  1843.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "unfiled")) {
  1844.                                         if (!file_exists("data/items/$entry_main/category.txt")) {
  1845.                                                 $items[] = $entry_main;
  1846.                                         }
  1847.                                 }
  1848.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "comments")) {
  1849.                                         if (count(glob("data/items/$entry_main/comments/live/*")) === 0) {
  1850.                                                 rmdir("data/items/$entry_main/comments/live");
  1851.                                         }
  1852.                                         if (file_exists("data/items/$entry_main/comments/live")) {
  1853.                                                 $items[] = $entry_main;
  1854.                                         }
  1855.                                 }
  1856.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "filedrop")) {
  1857.                                         if (count(glob("data/items/$entry_main/filedrop/*")) === 0) {
  1858.                                                 rmdir("data/items/$entry_main/filedrop");
  1859.                                         }
  1860.                                         if (file_exists("data/items/$entry_main/filedrop")) {
  1861.                                                 $items[] = $entry_main;
  1862.                                         }
  1863.                                 }
  1864.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "album")) {
  1865.                                         if (file_exists("images/$entry_main/album")) {
  1866.                                                 $items[] = $entry_main;
  1867.                                         }
  1868.                                 }
  1869.                                 else {
  1870.                                         $items[] = $entry_main;
  1871.                                 }
  1872.                         }
  1873.                 }
  1874.                 closedir($dh);
  1875.         }
  1876. }
  1877.  
  1878. if (!file_exists("data/old.txt")) {
  1879.         rsort($items);
  1880. }
  1881.  
  1882. if (file_exists("data/old.txt")) {
  1883.         sort($items);
  1884. }
  1885.  
  1886. if (isset($_REQUEST['category']) and !empty($_REQUEST['category'])) {
  1887.  
  1888.         $category = str_replace(" ", "-", $_REQUEST['category']);
  1889.         $category = strtolower($category);
  1890.         $category = strip_tags($category);
  1891.  
  1892.         if (file_exists("data/categories/$category/book.txt")) {
  1893.                 sort($items);
  1894.         }
  1895. }
  1896.  
  1897. reset($items);
  1898.  
  1899. $start = $_REQUEST['start'];
  1900.  
  1901. if (!isset($_REQUEST['start']) or empty($_REQUEST['start'])) {
  1902.         $start = 0;
  1903. }
  1904.  
  1905. $end=$start+$increase;
  1906.    
  1907. $disp=array_slice($items,$start,$increase);
  1908.  
  1909. foreach ($disp as $d) {
  1910.  
  1911.         if (file_exists("$dir/$d/category.txt")) {
  1912.                 $category_check = 'data/categories/' . file_get_contents("$dir/$d/category.txt");
  1913.                 if (!file_exists($category_check)) {
  1914.                         unlink("$dir/$d/category.txt");
  1915.                 }
  1916.         }
  1917.  
  1918.         if (file_exists("$dir/$d/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1919.                 continue;
  1920.         }
  1921.  
  1922.         if (file_exists("$dir/$d/member.txt") and (!isset($_SESSION['logged_in']))) {
  1923.                 continue;
  1924.         }
  1925.  
  1926.         echo '<table border=0 cellspacing=0 cellpadding=0 bgcolor=#cccccc style="background-color: transparent;"><tr><td width=';
  1927.         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  1928.                 echo "610";
  1929.         }
  1930.         else {
  1931.                 echo "525";
  1932.         }
  1933.         echo '>';
  1934.  
  1935.         if (file_exists("data/round.txt")) {
  1936.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  1937.         }
  1938.         else {
  1939.                 echo '<div id=panel_title>';
  1940.         }
  1941.  
  1942.         readfile("$dir/$d/title.txt");
  1943.  
  1944.         // start of wiki mod (20071130)
  1945.  
  1946.         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != $login_username) and file_exists("data/members/active/{$_SESSION['logged_in']}") and file_exists("data/wiki.txt") and (file_exists("$dir/$d/edit.txt") or (file_get_contents("$dir/$d/author.txt") == $_SESSION['logged_in'])) and file_exists("data/members/active/{$_SESSION['logged_in']}/rw.txt") and !file_exists("$dir/$d/passwd.txt")) {
  1947.  
  1948.                 if (file_exists("$dir/$d/wiki/delta") and (count(glob("$dir/$d/wiki/delta/*")) > 0)) {
  1949.                         echo "<a href=wiki.php?entry=$d>";
  1950.                         echo "<img src=images/widget.back.png border=0 width=11 height=11 align=right alt=revisions>";
  1951.                         echo "</a>";
  1952.                 }
  1953.  
  1954.                 echo '<a href=edit.php?entry=';
  1955.                 echo $d;
  1956.                 echo '><img src=images/widget.edit.png border=0 width=11 height=11 align=right alt="edit entry"></a>';
  1957.         }
  1958.  
  1959.         // end of wiki mod (20071130)
  1960.  
  1961.         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1962.  
  1963.                 echo '<a href=del.php?entry=';
  1964.                 echo $d;
  1965.                 echo '><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete entry"></a>';
  1966.  
  1967.                 if (!file_exists("$dir/$d/private.txt") and !file_exists("$dir/$d/category.txt") and file_exists("data/bb.txt") and (count(glob("$dir/$d/comments/live/*")) === 0) and (count(glob("$dir/$d/comments/pending/*")) === 0)) {
  1968.                         echo '<a href=move.php?entry=';
  1969.                         echo $d;
  1970.                         echo '><img src=images/widget.move.png border=0 width=11 height=11 align=right alt="move to comment"></a>';
  1971.                 }
  1972.  
  1973.  
  1974.                 if (file_exists("$dir/$d/wiki/delta") and (count(glob("$dir/$d/wiki/delta/*")) > 0)) {
  1975.                         echo "<a href=wiki.php?entry=$d>";
  1976.                         echo "<img src=images/widget.back.png border=0 width=11 height=11 align=right alt=revisions>";
  1977.                         echo "</a>";
  1978.                 }
  1979.  
  1980.                 echo '<a href=edit.php?entry=';
  1981.                 echo $d;
  1982.                 echo '><img src=images/widget.edit.png border=0 width=11 height=11 align=right alt="edit entry"></a>';
  1983.                 if (file_exists("$dir/$d/passwd.txt")) {
  1984.                         echo '<img src=images/widget.protected.png border=0 width=11 height=11 align=right alt="protected entry">';
  1985.                 }
  1986.  
  1987.                 if (file_exists("$dir/$d/private.txt")) {
  1988.                         echo '<img src=images/widget.private.png border=0 width=11 height=11 align=right alt="private entry">';
  1989.                 }
  1990.                 if (file_exists("$dir/$d/member.txt")) {
  1991.                         echo '<img src=images/widget.member.png border=0 width=11 height=11 align=right alt="member-only entry">';
  1992.                 }
  1993.                 if (file_exists("$dir/$d/cat.txt")) {
  1994.                         echo '<img src=images/widget.cat.png border=0 width=11 height=11 align=right alt="always display">';
  1995.                 }
  1996.                 if (file_exists("$dir/$d/category.txt")) {
  1997.  
  1998.                         $read_cat_dir = file_get_contents("$dir/$d/category.txt");
  1999.  
  2000.                         if (file_exists("data/categories/$read_cat_dir/private.txt")) {
  2001.                                 echo '<img src=images/widget.hidden.png border=0 width=11 height=11 align=right alt="category hidden">';
  2002.                         }
  2003.  
  2004.                         if (file_exists("data/nocat.txt")) {
  2005.                                 echo '<img src=images/widget.isolated.png border=0 width=11 height=11 align=right alt="category isolated">';
  2006.                         }
  2007.  
  2008.                         if (file_exists("data/categories/$read_cat_dir/book.txt")) {
  2009.                                 echo '<img src=images/widget.booked.png border=0 width=11 height=11 align=right alt="category booked">';
  2010.                         }
  2011.  
  2012.                         echo '<img src=images/widget.filed.png border=0 width=11 height=11 align=right alt="filed under ';
  2013.                         readfile("$dir/$d/category.txt");
  2014.                         echo '">';
  2015.                 }
  2016.  
  2017.         }
  2018.  
  2019.         echo '</div><div id=panel_entry_body><table border=0 cellspacing=0 cellpadding=0><tr>';
  2020.  
  2021.         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt") and file_exists("$dir/$d/author.txt")) {
  2022.                 echo "<td width=85 valign=top><p>";
  2023.                 $author = file_get_contents("$dir/$d/author.txt");
  2024.                 echo "<a href=member.php?id=$author>";
  2025.                 if ((file_get_contents("data/username.txt") == $author) and (file_exists("images/avatar.jpg") or file_exists("images/avatar.gif") or file_exists("images/avatar.png"))) {
  2026.                         if (file_exists("images/avatar.gif")) {
  2027.                                 $avatar_gif_image_size = getimagesize("images/avatar.gif");
  2028.                                 $avatar_gif_image_width = $avatar_gif_image_size[0];
  2029.                                 $avatar_gif_image_height = $avatar_gif_image_size[1];
  2030.  
  2031.                                 $max_avatar_gif_image_width = 80;
  2032.                        
  2033.                                 if ($avatar_gif_image_width > $max_avatar_gif_image_width) {  
  2034.                                         $sizefactor = (double) ($max_avatar_gif_image_width / $avatar_gif_image_width) ;
  2035.                                         $avatar_gif_image_width = (int) ($avatar_gif_image_width * $sizefactor);
  2036.                                         $avatar_gif_image_height = (int) ($avatar_gif_image_height * $sizefactor);
  2037.                                 }
  2038.  
  2039.                                 echo "<img src=images/avatar.gif border=0 width=";
  2040.                                 echo $avatar_gif_image_width;
  2041.                                 echo " height=";
  2042.                                 echo $avatar_gif_image_height;
  2043.                         }
  2044.                         if (file_exists("images/avatar.jpg")) {
  2045.                                 $avatar_jpg_image_size = getimagesize("images/avatar.jpg");
  2046.                                 $avatar_jpg_image_width = $avatar_jpg_image_size[0];
  2047.                                 $avatar_jpg_image_height = $avatar_jpg_image_size[1];
  2048.                        
  2049.                                 $max_avatar_jpg_image_width = 80;
  2050.                        
  2051.                                 if ($avatar_jpg_image_width > $max_avatar_jpg_image_width) {  
  2052.                                         $sizefactor = (double) ($max_avatar_jpg_image_width / $avatar_jpg_image_width) ;
  2053.                                         $avatar_jpg_image_width = (int) ($avatar_jpg_image_width * $sizefactor);
  2054.                                         $avatar_jpg_image_height = (int) ($avatar_jpg_image_height * $sizefactor);
  2055.                                 }
  2056.  
  2057.                                 echo "<img src=images/avatar.jpg border=0 width=";
  2058.                                 echo $avatar_jpg_image_width;
  2059.                                 echo " height=";
  2060.                                 echo $avatar_jpg_image_height;
  2061.                         }
  2062.                         if (file_exists("images/avatar.png")) {
  2063.                                 $avatar_png_image_size = getimagesize("images/avatar.png");
  2064.                                 $avatar_png_image_width = $avatar_png_image_size[0];
  2065.                                 $avatar_png_image_height = $avatar_png_image_size[1];
  2066.                        
  2067.                                 $max_avatar_png_image_width = 80;
  2068.                        
  2069.                                 if ($avatar_png_image_width > $max_avatar_png_image_width) {  
  2070.                                         $sizefactor = (double) ($max_avatar_png_image_width / $avatar_png_image_width) ;
  2071.                                         $avatar_png_image_width = (int) ($avatar_png_image_width * $sizefactor);
  2072.                                         $avatar_png_image_height = (int) ($avatar_png_image_height * $sizefactor);
  2073.                                 }
  2074.                        
  2075.                                 echo "<img src=images/avatar.png border=0 width=";
  2076.                                 echo $avatar_png_image_width;
  2077.                                 echo " height=";
  2078.                                 echo $avatar_png_image_height;
  2079.                         }
  2080.                 echo "><br>";
  2081.                 }
  2082.                 elseif (file_exists("images/members/$author/avatar.jpg") or file_exists("images/members/$author/avatar.gif") or file_exists("images/members/$author/avatar.png")) {
  2083.                         if (file_exists("images/members/$author/avatar.gif")) {
  2084.                                 $avatar_gif_image_size = getimagesize("images/members/$author/avatar.gif");
  2085.                                 $avatar_gif_image_width = $avatar_gif_image_size[0];
  2086.                                 $avatar_gif_image_height = $avatar_gif_image_size[1];
  2087.  
  2088.                                 $max_avatar_gif_image_width = 80;
  2089.                        
  2090.                                 if ($avatar_gif_image_width > $max_avatar_gif_image_width) {  
  2091.                                         $sizefactor = (double) ($max_avatar_gif_image_width / $avatar_gif_image_width) ;
  2092.                                         $avatar_gif_image_width = (int) ($avatar_gif_image_width * $sizefactor);
  2093.                                         $avatar_gif_image_height = (int) ($avatar_gif_image_height * $sizefactor);
  2094.                                 }
  2095.  
  2096.                                 echo "<img src=images/members/$author/avatar.gif border=0 width=";
  2097.                                 echo $avatar_gif_image_width;
  2098.                                 echo " height=";
  2099.                                 echo $avatar_gif_image_height;
  2100.                         }
  2101.                         if (file_exists("images/members/$author/avatar.jpg")) {
  2102.                                 $avatar_jpg_image_size = getimagesize("images/members/$author/avatar.jpg");
  2103.                                 $avatar_jpg_image_width = $avatar_jpg_image_size[0];
  2104.                                 $avatar_jpg_image_height = $avatar_jpg_image_size[1];
  2105.                        
  2106.                                 $max_avatar_jpg_image_width = 80;
  2107.                        
  2108.                                 if ($avatar_jpg_image_width > $max_avatar_jpg_image_width) {  
  2109.                                         $sizefactor = (double) ($max_avatar_jpg_image_width / $avatar_jpg_image_width) ;
  2110.                                         $avatar_jpg_image_width = (int) ($avatar_jpg_image_width * $sizefactor);
  2111.                                         $avatar_jpg_image_height = (int) ($avatar_jpg_image_height * $sizefactor);
  2112.                                 }
  2113.  
  2114.                                 echo "<img src=images/members/$author/avatar.jpg border=0 width=";
  2115.                                 echo $avatar_jpg_image_width;
  2116.                                 echo " height=";
  2117.                                 echo $avatar_jpg_image_height;
  2118.                         }
  2119.                         if (file_exists("images/members/$author/avatar.png")) {
  2120.                                 $avatar_png_image_size = getimagesize("images/members/$author/avatar.png");
  2121.                                 $avatar_png_image_width = $avatar_png_image_size[0];
  2122.                                 $avatar_png_image_height = $avatar_png_image_size[1];
  2123.                        
  2124.                                 $max_avatar_png_image_width = 80;
  2125.                        
  2126.                                 if ($avatar_png_image_width > $max_avatar_png_image_width) {  
  2127.                                         $sizefactor = (double) ($max_avatar_png_image_width / $avatar_png_image_width) ;
  2128.                                         $avatar_png_image_width = (int) ($avatar_png_image_width * $sizefactor);
  2129.                                         $avatar_png_image_height = (int) ($avatar_png_image_height * $sizefactor);
  2130.                                 }
  2131.                        
  2132.                                 echo "<img src=images/members/$author/avatar.png border=0 width=";
  2133.                                 echo $avatar_png_image_width;
  2134.                                 echo " height=";
  2135.                                 echo $avatar_png_image_height;
  2136.                         }
  2137.                 echo "><br>";
  2138.                 }
  2139.                 echo "<b>$author</b></a><br>";
  2140.                 if ((file_get_contents("data/username.txt") == $author) and file_exists("data/rank.txt")) {
  2141.                         echo "administrator<br>";
  2142.                 }
  2143.                 elseif (file_exists("data/members/active/$author/rank.txt") and file_exists("data/rank.txt")) {
  2144.                         $rank = file_get_contents("data/members/active/$author/rank.txt");
  2145.                         echo "$rank<br>";
  2146.                 }
  2147.                 elseif (!file_exists("data/members/active/$author/rank.txt") and file_exists("data/rank.txt")) {
  2148.                         echo "member<br>";
  2149.                 }
  2150.  
  2151.                 if ($dh_posts = opendir("data/items")) {
  2152.                         while (($entry_posts = readdir($dh_posts)) !== false) {
  2153.  
  2154.                                 if (file_exists("data/items/$entry_posts/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2155.                                         continue;
  2156.                                 }
  2157.  
  2158.                                 // hide_member (20070606)
  2159.                                 //if (file_exists("data/items/$entry_posts/member.txt") and (!isset($_SESSION['logged_in']))) {
  2160.                                 //      continue;
  2161.                                 //}
  2162.  
  2163.                                 $post_cat_dir = file_get_contents("data/items/$entry_posts/category.txt");
  2164.  
  2165.                                 if (file_exists("data/categories/$post_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_posts/cat.txt")) {
  2166.                                         continue;
  2167.                                 }
  2168.  
  2169.                                 if ($entry_posts != "." && $entry_posts != ".." && fnmatch("*", $entry_posts)) {
  2170.                                         if (file_exists("data/members/active/$author") and file_exists("data/bb.txt")) {
  2171.                                                 if (file_exists("data/items/$entry_posts/author.txt") and (file_get_contents("data/items/$entry_posts/author.txt") == $author)) {
  2172.                                                         $items_posts[] = $entry_posts;
  2173.                                                 }
  2174.                                         }
  2175.                                         elseif (!file_exists("data/members/active/$author") and (file_get_contents("data/username.txt") == $author) and file_exists("data/bb.txt")) {
  2176.                                                 if (file_exists("data/items/$entry_posts/author.txt") and (file_get_contents("data/items/$entry_posts/author.txt") == $author)) {
  2177.                                                         $items_posts[] = $entry_posts;
  2178.                                                 }
  2179.                                         }
  2180.                                 }
  2181.                         }
  2182.                 closedir($dh_posts);
  2183.                 }
  2184.                 $posts = count($items_posts);
  2185.                 if ($posts == 1) {
  2186.                         echo "$posts post";
  2187.                 }
  2188.                 if ($posts > 1) {
  2189.                         echo "$posts posts";
  2190.                 }
  2191.                 unset($items_posts);
  2192.  
  2193.                 echo "</p></td><td width=513 valign=top>";
  2194.  
  2195.         }
  2196.         else {
  2197.                 echo "<td width=598 valign=top>";
  2198.         }
  2199.  
  2200.         if (file_exists("$dir/$d/passwd.txt")) {
  2201.                 $passwd = file_get_contents("$dir/$d/passwd.txt");
  2202.         }
  2203.  
  2204.         if (isset($_REQUEST['passwd']) and !empty($_REQUEST['passwd'])) {
  2205.                 $crypt_passwd = sha1($_REQUEST['passwd']);
  2206.                 $crypt_passwd = md5($crypt_passwd);
  2207.                 $crypt_passwd = crypt($crypt_passwd, $crypt_passwd);
  2208.         }
  2209.  
  2210.         echo '<font style="font-size: 10px; color: #999999;">';
  2211.         if ((file_exists("$dir/$d/author.txt") and (file_exists("data/bb.txt") and !file_exists("data/avatar.txt")) or (file_exists("$dir/$d/author.txt") and (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username) and !file_exists("data/avatar.txt"))))) {
  2212.                 $xavatar_author = file_get_contents("$dir/$d/author.txt");
  2213.                 echo "<a href=member.php?id=$xavatar_author>$xavatar_author</a> - ";
  2214.         }
  2215.         readfile("$dir/$d/date.txt");
  2216.         if ((isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) or file_exists("$dir/$d/lastmod.txt")) {
  2217.                 if (file_exists("$dir/$d/revisions.txt")) {
  2218.                         echo ' (Revision ';
  2219.                         readfile("$dir/$d/revisions.txt");
  2220.                         echo " - ";
  2221.                         echo date("l, M j, Y, g:i A", filemtime("$dir/$d/body.txt"));
  2222.                         echo ')';
  2223.                 }
  2224.         }
  2225.         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2226.                 if (file_exists("$dir/$d/category.txt")) {
  2227.                         echo ' Filed under ';
  2228.                         $category_key = file_get_contents("$dir/$d/category.txt");
  2229.                         $category_key = strtolower($category_key);
  2230.                         if (file_exists("data/categories/{$category_key}/title.txt")) {
  2231.                                 $category_dsp = file_get_contents("data/categories/{$category_key}/title.txt");
  2232.                                 echo "$category_key ($category_dsp)";
  2233.                         }
  2234.                         else {
  2235.                                 echo "$category_key";
  2236.                         }
  2237.                 }
  2238.  
  2239.         }
  2240.         echo '</font><font style="font-size: 5px;"><br><br></font>';
  2241.  
  2242.         if (file_exists("$dir/$d/passwd.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['passwd']) or ($crypt_passwd != $passwd))) {
  2243.                 echo "This entry is password protected. If you know the magic word, click <a href=passwd.php?entry=$d>here</a> to enter it.";
  2244.         }
  2245.         else {
  2246.                 $entry_body = file_get_contents("$dir/$d/body.txt");
  2247.                 if (file_exists("data/pf.txt") and file_exists("data/pf-badwords.txt") and (!isset($_SESSION['logged_in']) or empty($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt"))))) {
  2248.                         $badwords = file_get_contents("data/pf-badwords.txt");
  2249.                         if (file_exists("data/pf-censor.txt")) {
  2250.                                 $censor = file_get_contents("data/pf-censor.txt");
  2251.                         }
  2252.                         else {
  2253.                                 $censor = "[expletive]";
  2254.                         }
  2255.                         $entry_body = preg_replace("/\b($badwords)\b/i",$censor,$entry_body);
  2256.                 }
  2257.                 echo $entry_body;
  2258.         }
  2259.  
  2260.         if ((file_get_contents("data/username.txt") == $author) and file_exists("data/sig.txt") and file_exists("data/bb.txt") and file_exists("data/bb-sig.txt")) {
  2261.                 $sig = file_get_contents("data/sig.txt");
  2262.                 echo "<br><br>--<br>$sig";
  2263.         }
  2264.         elseif (file_exists("data/members/active/$author/sig.txt") and file_exists("data/bb.txt")  and file_exists("data/bb-sig.txt")) {
  2265.                 $sig = file_get_contents("data/members/active/$author/sig.txt");
  2266.                 echo "<br><br>--<br>$sig";
  2267.         }
  2268.  
  2269.         echo '</td></tr></table>';
  2270.  
  2271.         if (file_exists("data/round.txt")) {
  2272.                 echo "<div class=rbspace></div>";
  2273.         }
  2274.  
  2275.         echo '</div><div id=panel_footer>';
  2276.         echo '<font style="font-size: 10px; color: ';
  2277.         if (file_exists("data/colors/pf-font.txt")) {
  2278.                 readfile("data/colors/pf-font.txt");
  2279.         }
  2280.         else {
  2281.                 echo "#999999";
  2282.         }
  2283.         echo ';">';
  2284.  
  2285. if (!file_exists("data/nocomment.txt") or (file_exists("data/memcomment.txt") and isset($_SESSION['logged_in']))) {
  2286.  
  2287.         if (!file_exists("$dir/$d/comments/live")) {
  2288.                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=comments>add comment</a>';
  2289.         }
  2290.         else {
  2291.                 if ($dh_comments = opendir("$dir/$d/comments/live")) {
  2292.                         while (($entry_comments = readdir($dh_comments)) !== false) {
  2293.                                 if ($entry_comments != "." && $entry_comments != ".." && fnmatch("*", $entry_comments)) {
  2294.                                         $items_comments[] = $entry_comments;
  2295.                                 }
  2296.                         }
  2297.                 closedir($dh_comments);
  2298.                 }
  2299.                 $comments = count($items_comments);
  2300.                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=comments>';
  2301.                 if ($comments == 1) {
  2302.                         echo $comments . ' comment';
  2303.                 }
  2304.                 elseif ($comments < 1) {
  2305.                         echo 'add comment';
  2306.                 }
  2307.                 else {
  2308.                         echo $comments . ' comments';
  2309.                 }
  2310.                 echo '</a>';
  2311.                 unset($items_comments);
  2312.         }
  2313.  
  2314. }
  2315. else {
  2316.         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '>permalink</a>';
  2317. }
  2318.  
  2319.         if (file_exists("$dir/$d/views.txt")) {
  2320.                 $fp_views_txt = fopen("$dir/$d/views.txt","r");
  2321.                 $views_value = fread($fp_views_txt,filesize("$dir/$d/views.txt"));
  2322.                 fclose($fp_views_txt);
  2323.                 if ($views_value == 1) {
  2324.                         echo ' ( ' . $views_value . ' view ) ';
  2325.                 }
  2326.                 elseif ($views_value > 1) {
  2327.                         echo ' ( ' . $views_value . ' views ) ';
  2328.                 }
  2329.                 else {
  2330.                         echo ' ';
  2331.                 }
  2332.         }
  2333.  
  2334.         if (!file_exists("images/$d/album")) {
  2335.                 echo ' ';
  2336.         }
  2337.         else {
  2338.                 if ($dh_album = opendir("images/$d/album")) {
  2339.                         while (($entry_album = readdir($dh_album)) !== false) {
  2340.                                 if ($entry_album != "." && $entry_album != ".." && fnmatch("*", $entry_album)) {
  2341.                                         $items_album[] = $entry_album;
  2342.                                 }
  2343.                         }
  2344.                 closedir($dh_album);
  2345.                 }
  2346.                 $album = count($items_album);
  2347.                 echo ' | <a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=album>';
  2348.                 if ($album == 1) {
  2349.                         echo $album . ' image';
  2350.                 }
  2351.                 elseif ($album < 1) {
  2352.                         echo 'album';
  2353.                 }
  2354.                 else {
  2355.                         echo $album . ' images';
  2356.                 }
  2357.                 echo '</a>';
  2358.                 unset($items_album);
  2359.         }
  2360.  
  2361.         if (file_exists("images/$d/album") and isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == album)) {
  2362.                 if (!file_exists("$dir/$d/album")) {
  2363.                         mkdir("$dir/$d/album");
  2364.                 }
  2365.                 if ((!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2366.                         $fp_album_views_txt = fopen("$dir/$d/album/views.txt","r");
  2367.                         $album_views_value = fread($fp_album_views_txt,filesize("$dir/$d/album/views.txt"));
  2368.                         fclose($fp_album_views_txt);
  2369.                         $album_views_value = $album_views_value + 1;
  2370.                         $fp_album_views_txt = fopen("$dir/$d/album/views.txt","w");
  2371.                         fwrite($fp_album_views_txt, $album_views_value);
  2372.                         fclose($fp_album_views_txt);
  2373.                 }
  2374.         }
  2375.  
  2376.         $fp_album_views_txt = fopen("$dir/$d/album/views.txt","r");
  2377.         $album_views_value = fread($fp_album_views_txt,filesize("$dir/$d/album/views.txt"));
  2378.         fclose($fp_album_views_txt);
  2379.         if ($album_views_value == 1) {
  2380.                 echo ' ( ' . $album_views_value . ' view ) ';
  2381.         }
  2382.         elseif ($album_views_value > 1) {
  2383.                 echo ' ( ' . $album_views_value . ' views ) ';
  2384.         }
  2385.         else {
  2386.                 echo ' ';
  2387.         }
  2388.  
  2389.         if (!file_exists("data/items/$d/filedrop/files")) {
  2390.                 echo ' ';
  2391.         }
  2392.         else {
  2393.                 if ($dh_filedrop = opendir("data/items/$d/filedrop/files")) {
  2394.                         while (($dl_file = readdir($dh_filedrop)) !== false) {
  2395.                                 if ($dl_file != "." && $dl_file != ".." && fnmatch("*", $dl_file)) {
  2396.                                         $items_filedrop[] = $dl_file;
  2397.                                 }
  2398.                         }
  2399.                 closedir($dh_filedrop);
  2400.                 }
  2401.                 $filedrop = count($items_filedrop);
  2402.                 echo ' | <a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=filedrop>';
  2403.                 if ($filedrop == 1) {
  2404.                         echo $filedrop . ' file';
  2405.                 }
  2406.                 elseif ($filedrop < 1) {
  2407.                         echo 'filedrop';
  2408.                 }
  2409.                 else {
  2410.                         echo $filedrop . ' files';
  2411.                 }
  2412.                 echo '</a> ';
  2413.                 unset($items_filedrop);
  2414.         }
  2415.  
  2416.         if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == filedrop)) {
  2417.                 if (!file_exists("$dir/$d/filedrop")) {
  2418.                         mkdir("$dir/$d/filedrop");
  2419.                 }
  2420.                 if (file_exists("data/items/$d/filedrop/files") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2421.                         $fp_filedrop_views_txt = fopen("$dir/$d/filedrop/views.txt","r");
  2422.                         $filedrop_views_value = fread($fp_filedrop_views_txt,filesize("$dir/$d/filedrop/views.txt"));
  2423.                         fclose($fp_filedrop_views_txt);
  2424.                         $filedrop_views_value = $filedrop_views_value + 1;
  2425.                         $fp_filedrop_views_txt = fopen("$dir/$d/filedrop/views.txt","w");
  2426.                         fwrite($fp_filedrop_views_txt, $filedrop_views_value);
  2427.                         fclose($fp_filedrop_views_txt);
  2428.                 }
  2429.         }
  2430.  
  2431.         $fp_filedrop_views_txt = fopen("$dir/$d/filedrop/views.txt","r");
  2432.         $filedrop_views_value = fread($fp_filedrop_views_txt,filesize("$dir/$d/filedrop/views.txt"));
  2433.         fclose($fp_filedrop_views_txt);
  2434.         if ($filedrop_views_value == 1) {
  2435.                 echo ' ( ' . $filedrop_views_value . ' view ) ';
  2436.         }
  2437.         elseif ($filedrop_views_value > 1) {
  2438.                 echo ' ( ' . $filedrop_views_value . ' views ) ';
  2439.         }
  2440.         else {
  2441.                 echo ' ';
  2442.         }
  2443.  
  2444.         if (!file_exists("data/nopdf.txt") and file_exists("$dir/$d/pdf/file")) {
  2445.  
  2446.                 echo "| <a href={$_SERVER['PHP_SELF']}?entry=$d&show=pdf>pdf</a> ";
  2447.  
  2448.                 if (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) {
  2449.                         $pdf_views_value = file_get_contents("$dir/$d/pdf/count/views.txt");
  2450.                         $pdf_views_value = $pdf_views_value + 1;
  2451.                         $fp_pdf_views_txt = fopen("$dir/$d/pdf/count/views.txt","w");
  2452.                         fwrite($fp_pdf_views_txt, $pdf_views_value);
  2453.                         fclose($fp_pdf_views_txt);
  2454.                 }
  2455.  
  2456.                 $pdf_views_value = file_get_contents("$dir/$d/pdf/count/views.txt");
  2457.                 if ($pdf_views_value == 1) {
  2458.                         echo ' ( ' . $pdf_views_value . ' view ) ';
  2459.                 }
  2460.                 elseif ($pdf_views_value > 1) {
  2461.                         echo ' ( ' . $pdf_views_value . ' views ) ';
  2462.                 }
  2463.                 else {
  2464.                         echo ' ';
  2465.                 }
  2466.         }
  2467.  
  2468.         if (!file_exists("data/nocomment.txt") or (file_exists("data/memcomment.txt") and isset($_SESSION['logged_in']))) {
  2469.                 echo '| <a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '>permalink</a></font>';
  2470.         }
  2471.  
  2472.         echo '</div>';
  2473.  
  2474.         if (file_exists("data/round.txt")) {
  2475.                 echo '<b class="rbbottom"><b class="rb4e"></b><b class="rb3e"></b><b class="rb2e"></b><b class="rb1e"></b></b>';
  2476.         }
  2477.  
  2478.         echo '</td></tr></table>';
  2479.  
  2480. // entry panel
  2481.  
  2482. unset($show_per_entry_panel_list);
  2483.  
  2484. if (file_exists("data/panels")) {
  2485.         if ($dh_per_entry_panel_list = opendir("data/panels")) {
  2486.                 while (($entry_per_entry_panel_list = readdir($dh_per_entry_panel_list)) !== false) {
  2487.  
  2488.                         if (file_exists("data/panels/$entry_per_entry_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2489.                                 continue;
  2490.                         }
  2491.  
  2492.                         if (!file_exists("data/panels/$entry_per_entry_panel_list/entry.txt")) {
  2493.                                 continue;
  2494.                         }
  2495.  
  2496.                         if ($entry_per_entry_panel_list != "." && $entry_per_entry_panel_list != ".." && fnmatch("*", $entry_per_entry_panel_list)) {
  2497.                                 $show_per_entry_panel_list[] = $entry_per_entry_panel_list;
  2498.                         }
  2499.                 }
  2500.                 closedir($dh_per_entry_panel_list);
  2501.         }
  2502.  
  2503.         sort($show_per_entry_panel_list);
  2504.         reset($show_per_entry_panel_list);
  2505.         $count_per_entry_panel_list = count($show_per_entry_panel_list);
  2506.        
  2507.         if ($count_per_entry_panel_list > 0) {
  2508.                 foreach ($show_per_entry_panel_list as $per_entry_panel_list_entry) {
  2509.                         if (!file_exists("data/panels/$per_entry_panel_list_entry/free.txt")) {
  2510.  
  2511.                                 if (file_exists("data/round.txt")) {
  2512.                                         echo '<b class="rbper_entry"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  2513.                                 }
  2514.                                 else {
  2515.                                         echo '<div id=panel_title>';
  2516.                                 }
  2517.  
  2518.                                 readfile("data/panels/$per_entry_panel_list_entry/title.txt");
  2519.  
  2520.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2521.                                         echo "<a href=panels.php#{$per_entry_panel_list_entry}>";
  2522.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  2523.                                 }
  2524.  
  2525.                                 echo '</div><div id=panel_body>';
  2526.                         }
  2527.  
  2528.                         if (file_exists("data/panels/$per_entry_panel_list_entry/free.txt")) {
  2529.                                 echo '<div id=panel_free>';
  2530.                         }
  2531.  
  2532.                         include("data/panels/$per_entry_panel_list_entry/panel.php");
  2533.                         echo '</div>';
  2534.  
  2535.                         if (file_exists("data/round.txt") and !file_exists("data/panels/$per_entry_panel_list_entry/free.txt")) {
  2536.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  2537.                         }
  2538.                 }
  2539.         }
  2540. }
  2541.  
  2542.  
  2543. // entry panel
  2544.  
  2545.  
  2546.  
  2547.         if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == album) and file_exists("images/$d/album")) {
  2548.                 echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  2549.  
  2550.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2551.                         echo "610";
  2552.                 }
  2553.                 else {
  2554.                         echo "525";
  2555.                 }
  2556.  
  2557.                 echo '><tr><td>';
  2558.  
  2559.                 if (file_exists("data/round.txt")) {
  2560.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  2561.                 }
  2562.                 else {
  2563.                         echo '<div id=panel_title>';
  2564.                 }
  2565.  
  2566.                 echo 'Album';
  2567.                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2568.                         echo '<a href=del.php?entry=';
  2569.                         echo $d;
  2570.                         echo '&target=album><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete album"></a>';
  2571.                 }
  2572.                 echo '</div><div id=panel_body>';
  2573.  
  2574.                 if (file_exists("$dir/$d/passwd.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['passwd']) or ($crypt_passwd != $passwd))) {
  2575.                         echo "This entry is password protected. If you know the magic word, click <a href=passwd.php?entry=$d&show=album>here</a> to enter it.";
  2576.                 }
  2577.                 else {
  2578.        
  2579.                         /* thumbnail auto-clean-up (20060409) - This should delete thumbnails of non-existent album images. */
  2580.        
  2581.                         if (file_exists("images/$d/thumbnails")) {
  2582.                                 if ($dh_album = opendir("images/$d/thumbnails")) {
  2583.                                         while (($thumbnail_album = readdir($dh_album)) !== false) {
  2584.                                                 if ($thumbnail_album != "." && $thumbnail_album != ".." && fnmatch("*", $thumbnail_album)) {
  2585.                                                         $current_thumbnail = "images/$d/thumbnails/$thumbnail_album";
  2586.                                                         $parent_image = str_replace("-thumbnail.jpg","",$thumbnail_album);
  2587.                                                         $parent_image = "images/$d/album/$parent_image";
  2588.                                                         if (file_exists($current_thumbnail) and !file_exists($parent_image)) {
  2589.                                                                 unlink($current_thumbnail);
  2590.                                                         }
  2591.                                                 }
  2592.                                         }
  2593.                                 }
  2594.                         }
  2595.  
  2596.                         /* caption auto-clean-up (20070216) This should delete captions of non-existent album images. */
  2597.  
  2598.                         if (file_exists("data/items/$d/album/captions")) {
  2599.                                 if ($dh_album = opendir("data/items/$d/album/captions")) {
  2600.                                         while (($caption_album = readdir($dh_album)) !== false) {
  2601.                                                 if ($caption_album != "." && $caption_album != ".." && fnmatch("*", $caption_album)) {
  2602.                                                         $current_caption = "data/items/$d/album/captions/$caption_album";
  2603.                                                         $parent_image = str_replace(".txt","",$caption_album);
  2604.                                                         $parent_image = "images/$d/album/$parent_image";
  2605.                                                         if (file_exists($current_caption) and !file_exists($parent_image)) {
  2606.                                                                 unlink($current_caption);
  2607.                                                         }
  2608.                                                 }
  2609.                                         }
  2610.                                 }
  2611.                         }
  2612.        
  2613.                         /* auto-sort entries (20060409) - MAJ previously relied on readdir() alone, causing entries to be displayed in the order in which they are stored by the filesystem. */
  2614.        
  2615.                         if (file_exists("images/$d/album")) {
  2616.                                 if ($dh_album = opendir("images/$d/album")) {
  2617.                                         while (($entry_album = readdir($dh_album)) !== false) {
  2618.                                                 if ($entry_album != "." && $entry_album != ".." && fnmatch("*", $entry_album)) {
  2619.                                                         $sort_album[] = $entry_album;
  2620.                                                 }
  2621.                                         }
  2622.                                 closedir($dh_album);
  2623.                                 }
  2624.        
  2625.                                 sort($sort_album);
  2626.                                 reset($sort_album);
  2627.                                 $count_album_entry = count($sort_album);
  2628.                                
  2629.                                 if ($count_album_entry < 1) {
  2630.                                         rmdirr("images/$d/album");
  2631.                                         rmdirr("images/$d/thumbnails");                        
  2632.                                 }
  2633.                                 else {
  2634.                                         foreach($sort_album as $album_entry) {
  2635.                                                 $current_image = "images/$d/album/$album_entry";
  2636.                                                 $current_image_size = getimagesize($current_image);
  2637.                                                 $current_width = $current_image_size[0];
  2638.                                                 $current_height = $current_image_size[1];
  2639.                                                 $max_width = 98;
  2640.                                                 $max_height = 73;
  2641.  
  2642.                                                 if (($current_width > $max_width) || ($current_height > $max_height)) {  
  2643.  
  2644.                                                         if ($current_height > $current_width) {
  2645.                                                                 $sizefactor = (double) ($max_height / $current_height);
  2646.                                                         }
  2647.                                                         else {
  2648.                                                                 $sizefactor = (double) ($max_width / $current_width) ;
  2649.                                                         }
  2650.  
  2651.                                                         $new_width = (int) ($current_width * $sizefactor);
  2652.                                                         $new_height = (int) ($current_height * $sizefactor);
  2653.                                                 }
  2654.                                                 else {
  2655.                                                         $new_width = $current_width;
  2656.                                                         $new_height = $current_height;
  2657.                                                 }
  2658.  
  2659.                                                 /* auto-thumbnails (20060213) - In maj-0.14-20060131, album thumbnails were simply the original images displayed with smaller "width=" and "height=" values. Album index loading was painfully slow since the browser had to download the original images from the server. This should speed things up. We placed the "function" here instead of edit.php or add.php to make auto-thumbnail generation available for maj-0.14-20060131 users who may already have existing albums. */
  2660.        
  2661.                                                 if (!file_exists("images/$d/thumbnails/{$album_entry}-thumbnail.jpg")) {
  2662.        
  2663.                                                         $work_thumb = imagecreatetruecolor($new_width,$new_height);
  2664.                                                         $get_mimetype = image_type_to_mime_type(exif_imagetype($current_image));
  2665.  
  2666.                                                         switch($get_mimetype) {
  2667.                                                                 case "image/jpg":
  2668.                                                                 case "image/jpeg":
  2669.                                                                         $work_image = imagecreatefromjpeg($current_image);
  2670.                                                                         break;
  2671.                                                                 case "image/gif":
  2672.                                                                         $work_image = imagecreatefromgif($current_image);
  2673.                                                                         break;
  2674.                                                                 case "image/png":
  2675.                                                                         $work_image = imagecreatefrompng($current_image);
  2676.                                                                         break;
  2677.                                                         }
  2678.        
  2679.                                                         imagecopyresampled($work_thumb,$work_image,0,0,0,0,$new_width,$new_height,$current_width,$current_height);
  2680.        
  2681.                                                         if (!file_exists("images/$d/thumbnails")) {
  2682.                                                                 mkdir("images/$d/thumbnails");
  2683.                                                         }
  2684.        
  2685.                                                         imagejpeg($work_thumb,"images/$d/thumbnails/{$album_entry}-thumbnail.jpg",80);
  2686.        
  2687.                                                 }
  2688.  
  2689.                                                 echo "<a href=\"album.php?entry=$d&show=$album_entry\">";
  2690.  
  2691.                                                 /* auto-thumbnails (20060519) - Just in case php-gd does not exist, do it the old way. */
  2692.  
  2693.                                                 if (!file_exists("images/$d/thumbnails/{$album_entry}-thumbnail.jpg")) {
  2694.                                                         echo "<img src=\"images/$d/album/$album_entry\" width=$new_width height=$new_height border=0 hspace=2 vspace=2";
  2695.                                                 }
  2696.                                                 else {
  2697.                                                         echo "<img src=\"images/$d/thumbnails/{$album_entry}-thumbnail.jpg\" width=$new_width height=$new_height border=0 hspace=2 vspace=2";
  2698.                                                 }
  2699.  
  2700.                                                 if (file_exists("data/items/$d/album/captions/{$album_entry}.txt")) {
  2701.                                                         echo ' alt="';
  2702.                                                         $img_alt = file_get_contents("data/items/$d/album/captions/{$album_entry}.txt");
  2703.                                                         $img_alt = strip_tags($img_alt);
  2704.                                                         echo $img_alt;
  2705.                                                         echo '"';
  2706.                                                 }
  2707.                                                 echo "></a>";
  2708.                                         }
  2709.                                 }
  2710.                         }
  2711.                 }
  2712.                 echo '</div>';
  2713.  
  2714.                 if (file_exists("data/round.txt")) {
  2715.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  2716.                 }
  2717.  
  2718.                 echo '</td></tr></table>';
  2719.  
  2720.         }
  2721.  
  2722.         if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == filedrop) and file_exists("$dir/$d/filedrop/files")) {
  2723.                 echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  2724.  
  2725.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2726.                         echo "610";
  2727.                 }
  2728.                 else {
  2729.                         echo "525";
  2730.                 }
  2731.  
  2732.                 echo '><tr><td>';
  2733.  
  2734.                 if (file_exists("data/round.txt")) {
  2735.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  2736.                 }
  2737.                 else {
  2738.                         echo "<div id=panel_title>";
  2739.                 }
  2740.  
  2741.                 echo "Filedrop";
  2742.  
  2743.                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2744.                         echo "<a href=del.php?entry=$d&target=filedrop><img src=images/widget.del.png border=0 width=11 height=11 align=right alt=\"delete filedrop\"></a>";
  2745.                 }
  2746.                 echo "</div><div id=panel_body>";
  2747.  
  2748.                 if (file_exists("$dir/$d/passwd.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['passwd']) or ($crypt_passwd != $passwd))) {
  2749.                         echo "This entry is password protected. If you know the magic word, click <a href=passwd.php?entry=$d&show=filedrop>here</a> to enter it.";
  2750.                 }
  2751.                 else {
  2752.  
  2753.                         if ($dh_filedrop = opendir("data/items/$d/filedrop/files")) {
  2754.                                 while (($dl_file = readdir($dh_filedrop)) !== false) {
  2755.                                         if ($dl_file != "." && $dl_file != ".." && fnmatch("*", $dl_file)) {
  2756.                                                 $filedrop_files[] = $dl_file;
  2757.                                         }
  2758.                                 }
  2759.                         closedir($dh_filedrop);
  2760.                         }
  2761.  
  2762.                         reset($filedrop_files);
  2763.                         sort($filedrop_files);
  2764.  
  2765.                         foreach ($filedrop_files as $filedrop_file) {
  2766.  
  2767.                                 echo "<table border=0 cellspacing=0 cellpadding=4><tr><td>";
  2768.                                 echo "<a href=\"{$_SERVER['PHP_SELF']}?entry=$d&download=$filedrop_file&type=filedrop\">";
  2769.                                 echo "<img src=images/filedrop.png width=36 height=36 border=0 alt=\"download file\"></a></td>";
  2770.                                 echo "<td><p><b>$filedrop_file</b>";
  2771.  
  2772.                                 if (file_exists("data/items/$d/filedrop/sha1.txt")) {
  2773.                                         $sha1 = sha1_file("data/items/$d/filedrop/files/$filedrop_file");
  2774.                                         echo "<br />$sha1 (<a href=http://www.faqs.org/rfcs/rfc3174 target=_maj>sha1</a>)";
  2775.                                 }
  2776.                                 if (file_exists("data/items/$d/filedrop/md5.txt")) {
  2777.                                         $md5 = md5_file("data/items/$d/filedrop/files/$filedrop_file");
  2778.                                         echo "<br />$md5 (<a href=http://www.faqs.org/rfcs/rfc1321 target=_maj>md5</a>)";
  2779.                                 }
  2780.  
  2781.                                 $size = filesize("data/items/$d/filedrop/files/$filedrop_file");
  2782.                                 $size_string = ($size > 512)?(  ($size/1024 > 512)  ?sprintf("%.02f MB",($size/1024)/1024)  :sprintf("%.02f KB",$size/1024))  :sprintf("%d B",$size);
  2783.  
  2784.                                 echo "<br />$size_string";
  2785.  
  2786.                                 $filedrop_count_file = "data/items/$d/filedrop/count/$filedrop_file" . '.txt';
  2787.  
  2788.                                 if (file_exists($filedrop_count_file)) {
  2789.                                         $fp_filedrop_count = fopen($filedrop_count_file, "r");
  2790.                                         $filedrop_count = fread($fp_filedrop_count, filesize($filedrop_count_file));
  2791.                                         fclose($fp_filedrop_count);
  2792.                                         echo "<br>$filedrop_count";
  2793.                                
  2794.                                         if ($filedrop_count == 1) {
  2795.                                                 echo " download";
  2796.                                         }
  2797.                                         if ($filedrop_count > 1) {
  2798.                                                 echo " downloads";
  2799.                                         }
  2800.                                 }
  2801.                                 echo "</p></td></tr></table>";
  2802.                         }
  2803.                 }
  2804.                 echo "</div>";
  2805.  
  2806.                 if (file_exists("data/round.txt")) {
  2807.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  2808.                 }
  2809.  
  2810.                 echo '</td></tr></table>';
  2811.         }
  2812.  
  2813.         if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == pdf) and file_exists("data/items/$d/pdf/file")) {
  2814.                 echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  2815.  
  2816.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2817.                         echo "610";
  2818.                 }
  2819.                 else {
  2820.                         echo "525";
  2821.                 }
  2822.  
  2823.                 echo '><tr><td>';
  2824.  
  2825.                 if (file_exists("data/round.txt")) {
  2826.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  2827.                 }
  2828.                 else {
  2829.                         echo '<div id=panel_title>';
  2830.                 }
  2831.  
  2832.                 echo 'PDF';
  2833.                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2834.                         echo '<a href=del.php?entry=';
  2835.                         echo $d;
  2836.                         echo '&target=pdf><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete pdf"></a>';
  2837.                 }
  2838.                 echo '</div><div id=panel_body>';
  2839.  
  2840.                 if (file_exists("$dir/$d/passwd.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['passwd']) or ($crypt_passwd != $passwd))) {
  2841.                         echo "This entry is password protected. If you know the magic word, click <a href=passwd.php?entry=$d&show=pdf>here</a> to enter it.";
  2842.                 }
  2843.                 else {
  2844.  
  2845.                         if ($dh_pdf = opendir("data/items/$d/pdf/file")) {
  2846.                                 while (($dl_file = readdir($dh_pdf)) !== false) {
  2847.                                         if ($dl_file != "." && $dl_file != ".." && fnmatch("*", $dl_file)) {
  2848.                                                 echo '<table border=0 cellspacing=0 cellpadding=4><tr><td>';
  2849.                                                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&download=' . $dl_file. '&type=pdf>';
  2850.                                                 echo '<img src=images/pdf.png width=48 height=48 border=0 alt="download file"></a></td>';
  2851.                                                 echo '<td><p><b>';
  2852.                                                 echo $dl_file;
  2853.                                                 echo'</b><br>';
  2854.                                                 $size = filesize("data/items/$d/pdf/file/$dl_file");
  2855.                                                 $size_string = ($size > 512)?(  ($size/1024 > 512)  ?sprintf("%.02f MB",($size/1024)/1024)  :sprintf("%.02f KB",$size/1024))  :sprintf("%d B",$size);
  2856.                                                 echo $size_string;
  2857.                                                 $pdf_count_file = "data/items/$d/pdf/count/dl.txt";
  2858.                                                 if (file_exists($pdf_count_file)) {
  2859.                                                         $fp_pdf_count = fopen($pdf_count_file, "r");
  2860.                                                         $pdf_count = fread($fp_pdf_count, filesize($pdf_count_file));
  2861.                                                         fclose($fp_pdf_count);
  2862.                                                         echo '<br>';
  2863.                                                         echo $pdf_count;
  2864.                                                         if ($pdf_count == 1) {
  2865.                                                                 echo ' download';
  2866.                                                         }
  2867.                                                         if ($pdf_count > 1) {
  2868.                                                                 echo ' downloads';
  2869.                                                         }
  2870.                                                 }
  2871.                                                 echo '</p></td></tr></table>';
  2872.                                         }
  2873.                                 }
  2874.                         closedir($dh_pdf);
  2875.                         }
  2876.                 }
  2877.                 echo '</div>';
  2878.  
  2879.                 if (file_exists("data/round.txt")) {
  2880.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  2881.                 }
  2882.  
  2883.                 echo '</td></tr></table>';
  2884.         }
  2885.  
  2886.         if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == comments) and (!file_exists("data/nocomment.txt") or (file_exists("data/memcomment.txt") and isset($_SESSION['logged_in'])))) {
  2887.  
  2888.                 if (file_exists("$dir/$d/passwd.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['passwd']) or ($crypt_passwd != $passwd))) {
  2889.                 }
  2890.                 else {
  2891.                         echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  2892.  
  2893.                         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2894.                                 echo "610";
  2895.                         }
  2896.                         else {
  2897.                                 echo "525";
  2898.                         }
  2899.  
  2900.                         echo '><tr><td>';
  2901.                         if ($dh_comments = opendir("$dir/$d/comments/live")) {
  2902.                                 while (($entry_comments = readdir($dh_comments)) !== false) {
  2903.                                         if ($entry_comments != "." && $entry_comments != ".." && fnmatch("*", $entry_comments)) {
  2904.                                                 $show_comments[] = $entry_comments;
  2905.                                         }
  2906.                                 }
  2907.                         closedir($dh_comments);
  2908.                         }
  2909.        
  2910.                         asort($show_comments);
  2911.                         reset($show_comments);
  2912.                         foreach ($show_comments as $comment) {
  2913.  
  2914.                                 if (file_exists("data/round.txt")) {
  2915.                                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  2916.                                 }
  2917.                                 else {
  2918.                                         echo '<div id=panel_title>';
  2919.                                 }
  2920.        
  2921.                                 if (file_exists("$dir/$d/comments/live/$comment/url.txt")) {
  2922.                                         echo '<a target=_maj href=';
  2923.                                         readfile("$dir/$d/comments/live/$comment/url.txt");
  2924.                                         echo '>';
  2925.                                 }
  2926.        
  2927.                                 readfile("$dir/$d/comments/live/$comment/firstname.txt");
  2928.                                 echo ' ';
  2929.                                 readfile("$dir/$d/comments/live/$comment/lastname.txt");
  2930.        
  2931.                                 if (file_exists("$dir/$d/comments/live/$comment/url.txt")) {
  2932.                                         echo '</a>';
  2933.                                 }
  2934.        
  2935.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2936.                                         echo '  &lt;';
  2937.                                         readfile("$dir/$d/comments/live/$comment/email.txt");
  2938.                                         echo '&gt;';
  2939.                                 }
  2940.        
  2941.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2942.                                         echo '<a href=del.php?entry=' . $d . '&comment=' . $comment . '&type=live><img src=images/widget.del.png width=11 height=11 border=0 align=right alt="delete comment"></a>';
  2943.                                         echo '<a href=move.php?entry=' . $d . '&comment=' . $comment . '&type=live><img src=images/widget.move.png width=11 height=11 border=0 align=right alt="move comment"></a>';
  2944.                                         echo '<a href=edit.php?entry=' . $d . '&comment=' . $comment . '&type=live><img src=images/widget.edit.png width=11 height=11 border=0 align=right alt="edit comment"></a>';
  2945.                                 }
  2946.                                 echo '</div><div id=panel_body><table border=0 cellspacing=0 cellpadding=0><tr>';
  2947.                                
  2948.                                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt") and file_exists("$dir/$d/comments/live/$comment/author.txt")) {
  2949.                                         echo "<td width=85 valign=top><p>";
  2950.                                         $c_author = file_get_contents("$dir/$d/comments/live/$comment/author.txt");
  2951.                                         echo "<a href=member.php?id=$c_author>";
  2952.                                         if ((file_get_contents("data/username.txt") == $c_author) and (file_exists("images/avatar.jpg") or file_exists("images/avatar.gif") or file_exists("images/avatar.png"))) {
  2953.                                                 if (file_exists("images/avatar.gif")) {
  2954.                                                         $c_avatar_gif_image_size = getimagesize("images/avatar.gif");
  2955.                                                         $c_avatar_gif_image_width = $c_avatar_gif_image_size[0];
  2956.                                                         $c_avatar_gif_image_height = $c_avatar_gif_image_size[1];
  2957.                        
  2958.                                                         $c_max_avatar_gif_image_width = 80;
  2959.                                                
  2960.                                                         if ($c_avatar_gif_image_width > $c_max_avatar_gif_image_width) {  
  2961.                                                                 $sizefactor = (double) ($c_max_avatar_gif_image_width / $c_avatar_gif_image_width) ;
  2962.                                                                 $c_avatar_gif_image_width = (int) ($c_avatar_gif_image_width * $sizefactor);
  2963.                                                                 $c_avatar_gif_image_height = (int) ($c_avatar_gif_image_height * $sizefactor);
  2964.                                                         }
  2965.                        
  2966.                                                         echo "<img src=images/avatar.gif border=0 width=";
  2967.                                                         echo $c_avatar_gif_image_width;
  2968.                                                         echo " height=";
  2969.                                                         echo $c_avatar_gif_image_height;
  2970.                                                 }
  2971.                                                 if (file_exists("images/avatar.jpg")) {
  2972.                                                         $c_avatar_jpg_image_size = getimagesize("images/avatar.jpg");
  2973.                                                         $c_avatar_jpg_image_width = $c_avatar_jpg_image_size[0];
  2974.                                                         $c_avatar_jpg_image_height = $c_avatar_jpg_image_size[1];
  2975.                                                
  2976.                                                         $c_max_avatar_jpg_image_width = 80;
  2977.                                                
  2978.                                                         if ($c_avatar_jpg_image_width > $c_max_avatar_jpg_image_width) {  
  2979.                                                                 $sizefactor = (double) ($c_max_avatar_jpg_image_width / $c_avatar_jpg_image_width) ;
  2980.                                                                 $c_avatar_jpg_image_width = (int) ($c_avatar_jpg_image_width * $sizefactor);
  2981.                                                                 $c_avatar_jpg_image_height = (int) ($c_avatar_jpg_image_height * $sizefactor);
  2982.                                                         }
  2983.                        
  2984.                                                         echo "<img src=images/avatar.jpg border=0 width=";
  2985.                                                         echo $c_avatar_jpg_image_width;
  2986.                                                         echo " height=";
  2987.                                                         echo $c_avatar_jpg_image_height;
  2988.                                                 }
  2989.                                                 if (file_exists("images/avatar.png")) {
  2990.                                                         $c_avatar_png_image_size = getimagesize("images/avatar.png");
  2991.                                                         $c_avatar_png_image_width = $c_avatar_png_image_size[0];
  2992.                                                         $c_avatar_png_image_height = $c_avatar_png_image_size[1];
  2993.                                                
  2994.                                                         $c_max_avatar_png_image_width = 80;
  2995.                                                
  2996.                                                         if ($c_avatar_png_image_width > $c_max_avatar_png_image_width) {  
  2997.                                                                 $sizefactor = (double) ($c_max_avatar_png_image_width / $c_avatar_png_image_width) ;
  2998.                                                                 $c_avatar_png_image_width = (int) ($c_avatar_png_image_width * $sizefactor);
  2999.                                                                 $c_avatar_png_image_height = (int) ($c_avatar_png_image_height * $sizefactor);
  3000.                                                         }
  3001.                                                
  3002.                                                         echo "<img src=images/avatar.png border=0 width=";
  3003.                                                         echo $c_avatar_png_image_width;
  3004.                                                         echo " height=";
  3005.                                                         echo $c_avatar_png_image_height;
  3006.                                                 }
  3007.                                         echo "><br>";
  3008.                                         }
  3009.                                         elseif (file_exists("images/members/$c_author/avatar.jpg") or file_exists("images/members/$c_author/avatar.gif") or file_exists("images/members/$c_author/avatar.png")) {
  3010.                                                 if (file_exists("images/members/$c_author/avatar.gif")) {
  3011.                                                         $c_avatar_gif_image_size = getimagesize("images/members/$c_author/avatar.gif");
  3012.                                                         $c_avatar_gif_image_width = $c_avatar_gif_image_size[0];
  3013.                                                         $c_avatar_gif_image_height = $c_avatar_gif_image_size[1];
  3014.                        
  3015.                                                         $c_max_avatar_gif_image_width = 80;
  3016.                                                
  3017.                                                         if ($c_avatar_gif_image_width > $c_max_avatar_gif_image_width) {  
  3018.                                                                 $sizefactor = (double) ($c_max_avatar_gif_image_width / $c_avatar_gif_image_width) ;
  3019.                                                                 $c_avatar_gif_image_width = (int) ($c_avatar_gif_image_width * $sizefactor);
  3020.                                                                 $c_avatar_gif_image_height = (int) ($c_avatar_gif_image_height * $sizefactor);
  3021.                                                         }
  3022.                        
  3023.                                                         echo "<img src=images/members/$c_author/avatar.gif border=0 width=";
  3024.                                                         echo $c_avatar_gif_image_width;
  3025.                                                         echo " height=";
  3026.                                                         echo $c_avatar_gif_image_height;
  3027.                                                 }
  3028.                                                 if (file_exists("images/members/$c_author/avatar.jpg")) {
  3029.                                                         $c_avatar_jpg_image_size = getimagesize("images/members/$c_author/avatar.jpg");
  3030.                                                         $c_avatar_jpg_image_width = $c_avatar_jpg_image_size[0];
  3031.                                                         $c_avatar_jpg_image_height = $c_avatar_jpg_image_size[1];
  3032.                                                
  3033.                                                         $c_max_avatar_jpg_image_width = 80;
  3034.                                                
  3035.                                                         if ($c_avatar_jpg_image_width > $c_max_avatar_jpg_image_width) {  
  3036.                                                                 $sizefactor = (double) ($c_max_avatar_jpg_image_width / $c_avatar_jpg_image_width) ;
  3037.                                                                 $c_avatar_jpg_image_width = (int) ($c_avatar_jpg_image_width * $sizefactor);
  3038.                                                                 $c_avatar_jpg_image_height = (int) ($c_avatar_jpg_image_height * $sizefactor);
  3039.                                                         }
  3040.                        
  3041.                                                         echo "<img src=images/members/$c_author/avatar.jpg border=0 width=";
  3042.                                                         echo $c_avatar_jpg_image_width;
  3043.                                                         echo " height=";
  3044.                                                         echo $c_avatar_jpg_image_height;
  3045.                                                 }
  3046.                                                 if (file_exists("images/members/$c_author/avatar.png")) {
  3047.                                                         $c_avatar_png_image_size = getimagesize("images/members/$c_author/avatar.png");
  3048.                                                         $c_avatar_png_image_width = $c_avatar_png_image_size[0];
  3049.                                                         $c_avatar_png_image_height = $c_avatar_png_image_size[1];
  3050.                                                
  3051.                                                         $c_max_avatar_png_image_width = 80;
  3052.                                                
  3053.                                                         if ($c_avatar_png_image_width > $c_max_avatar_png_image_width) {  
  3054.                                                                 $sizefactor = (double) ($c_max_avatar_png_image_width / $c_avatar_png_image_width) ;
  3055.                                                                 $c_avatar_png_image_width = (int) ($c_avatar_png_image_width * $sizefactor);
  3056.                                                                 $c_avatar_png_image_height = (int) ($c_avatar_png_image_height * $sizefactor);
  3057.                                                         }
  3058.                                                
  3059.                                                         echo "<img src=images/members/$c_author/avatar.png border=0 width=";
  3060.                                                         echo $c_avatar_png_image_width;
  3061.                                                         echo " height=";
  3062.                                                         echo $c_avatar_png_image_height;
  3063.                                                 }
  3064.                                         echo "><br>";
  3065.                                         }
  3066.                                         echo "$c_author</a><br>";
  3067.                                         if ((file_get_contents("data/username.txt") == $c_author) and file_exists("data/rank.txt")) {
  3068.                                                 echo "administrator<br>";
  3069.                                         }
  3070.                                         elseif (file_exists("data/members/active/$c_author/rank.txt") and file_exists("data/rank.txt")) {
  3071.                                                 $c_rank = file_get_contents("data/members/active/$c_author/rank.txt");
  3072.                                                 echo "$c_rank<br>";
  3073.                                         }
  3074.                                         elseif (!file_exists("data/members/active/$c_author/rank.txt") and file_exists("data/rank.txt")) {
  3075.                                                 echo "member<br>";
  3076.                                         }
  3077.                        
  3078.                                         if ($c_dh_posts = opendir("data/items")) {
  3079.                                                 while (($c_entry_posts = readdir($c_dh_posts)) !== false) {
  3080.                        
  3081.                                                         if (file_exists("data/items/$c_entry_posts/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3082.                                                                 continue;
  3083.                                                         }
  3084.                        
  3085.                                                         if (file_exists("data/items/$c_entry_posts/member.txt") and (!isset($_SESSION['logged_in']))) {
  3086.                                                                 continue;
  3087.                                                         }
  3088.                        
  3089.                                                         $c_post_cat_dir = file_get_contents("data/items/$c_entry_posts/category.txt");
  3090.                        
  3091.                                                         if (file_exists("data/categories/$c_post_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$c_entry_posts/cat.txt")) {
  3092.                                                                 continue;
  3093.                                                         }
  3094.                        
  3095.                                                         if ($c_entry_posts != "." && $c_entry_posts != ".." && fnmatch("*", $c_entry_posts)) {
  3096.                                                                 if (file_exists("data/members/active/$c_author") and file_exists("data/bb.txt")) {
  3097.                                                                         if (file_exists("data/items/$c_entry_posts/author.txt") and (file_get_contents("data/items/$c_entry_posts/author.txt") == $c_author)) {
  3098.                                                                                 $c_items_posts[] = $c_entry_posts;
  3099.                                                                         }
  3100.                                                                 }
  3101.                                                                 elseif (!file_exists("data/members/active/$c_author") and (file_get_contents("data/username.txt") == $c_author) and file_exists("data/bb.txt")) {
  3102.                                                                         if (file_exists("data/items/$c_entry_posts/author.txt") and (file_get_contents("data/items/$c_entry_posts/author.txt") == $c_author)) {
  3103.                                                                                 $c_items_posts[] = $c_entry_posts;
  3104.                                                                         }
  3105.                                                                 }
  3106.                                                         }
  3107.                                                 }
  3108.                                         closedir($c_dh_posts);
  3109.                                         }
  3110.                                         $c_posts = count($c_items_posts);
  3111.                                         if ($c_posts == 1) {
  3112.                                                 echo "$c_posts post";
  3113.                                         }
  3114.                                         if ($c_posts > 1) {
  3115.                                                 echo "$c_posts posts";
  3116.                                         }
  3117.                                         unset($c_items_posts);
  3118.                        
  3119.                                         echo "</p></td><td width=513 valign=top>";
  3120.                                 }
  3121.                                 else {
  3122.                                         echo "<td width=598 valign=top>";
  3123.                                 }
  3124.  
  3125.                                 echo '<p><font style="font-size: 10px; color: #999999;">';
  3126.                                 if ((file_exists("$dir/$d/comments/live/$comment/author.txt") and (file_exists("data/bb.txt") and !file_exists("data/avatar.txt")) or (file_exists("$dir/$d/comments/live/$comment/author.txt") and (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username) and !file_exists("data/avatar.txt"))))) {
  3127.                                         $cxavatar_author = file_get_contents("$dir/$d/comments/live/$comment/author.txt");
  3128.                                         echo "<a href=member.php?id=$cxavatar_author>$cxavatar_author</a> - ";
  3129.                                 }
  3130.                                 readfile("$dir/$d/comments/live/$comment/timestamp.txt");
  3131.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  3132.                                         if (file_exists("$dir/$d/comments/live/$comment/revisions.txt")) {
  3133.                                                 echo '  (Revision ';
  3134.                                                 readfile("$dir/$d/comments/live/$comment/revisions.txt");
  3135.                                                 echo ')';
  3136.                                         }
  3137.                                 }
  3138.                                 echo '</font><font style="font-size: 5px;"><br><br></font>';
  3139.                                 $entry_comment = file_get_contents("$dir/$d/comments/live/$comment/comment.txt");
  3140.                                 if (file_exists("data/pf.txt") and file_exists("data/pf-badwords.txt") and (!isset($_SESSION['logged_in']) or empty($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt"))))) {
  3141.                                         $badwords = file_get_contents("data/pf-badwords.txt");
  3142.                                         if (file_exists("data/pf-censor.txt")) {
  3143.                                                 $censor = file_get_contents("data/pf-censor.txt");
  3144.                                         }
  3145.                                         else {
  3146.                                                 $censor = "[expletive]";
  3147.                                         }
  3148.                                         $entry_comment = preg_replace("/\b($badwords)\b/i",$censor,$entry_comment);
  3149.                                 }
  3150.                                 echo $entry_comment;
  3151.                                 echo '</p></tr></table></div>';
  3152.  
  3153.                                 if (file_exists("data/round.txt")) {
  3154.                                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  3155.                                 }
  3156.                         }
  3157.                         unset($show_comments);
  3158.                         echo '</td></tr></table>';
  3159.                 }
  3160.  
  3161. if (!file_exists("data/nocomment.txt") or (file_exists("data/memcomment.txt") and isset($_SESSION['logged_in']))) {
  3162.  
  3163.                 echo '<p><table border=0 cellspacing=0 cellpadding=0 width=';
  3164.  
  3165.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  3166.                         echo "610";
  3167.                 }
  3168.                 else {
  3169.                         echo "525";
  3170.                 }
  3171.  
  3172.                 echo '><tr><td>';
  3173.                 echo '<p><font style="font-size: 12px;"><b>Add Comment</b></font></p>';
  3174.  
  3175.                 if (file_exists("$dir/$d/passwd.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and (!isset($_REQUEST['passwd']) or ($crypt_passwd != $passwd))) {
  3176.                         echo "<p>This entry is password protected. If you know the magic word, click <a href=passwd.php?entry=$d&show=comments>here</a> to enter it.</p>";
  3177.                 }
  3178.                 else {
  3179.        
  3180.                         $captcha_rand = str_rand(7);
  3181.        
  3182.                         echo "<p>Fill out the form below";
  3183.  
  3184.                         if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")))) {
  3185.                                 echo " and enter <b>$captcha_rand</b> in the anti-spam field";
  3186.                         }
  3187.  
  3188.                         echo " to add your comment.";
  3189.  
  3190.                         if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")))) {
  3191.                                 echo " Note that it will not be posted immediately, but will be ";
  3192.                        
  3193.                                 if (file_exists("data/email.txt")) {
  3194.                                         echo "e-mailed";
  3195.                                 }
  3196.                                 else {
  3197.                                         echo "sent";
  3198.                                 }
  3199.        
  3200.                                 echo " to me first.";
  3201.  
  3202.                                 if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and !file_exists("data/members/active/{$_SESSION['logged_in']}"))) {
  3203.                                         echo " Comments with bogus contact information will be discarded.";
  3204.                                 }
  3205.                         }
  3206.                         echo "</p>";
  3207.  
  3208.                         ?>
  3209.                        
  3210.                         <table border=0 cellspacing=2 cellpadding=0 width=500>
  3211.                         <form enctype="multipart/form-data" action="<?php echo $_SERVER['PHP_SELF']; ?>?entry=<?php echo $d; ?>&show=comments" method="post">
  3212.                         <input type=hidden name=captcha_get value="<?php echo $captcha_rand; ?>">
  3213.                         <tr>
  3214.  
  3215. <?php
  3216. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  3217. ?>
  3218.         <td width=75><p></p></td><td><input type=hidden name=cauthor value="<?php echo $_SESSION['logged_in']; ?>"><input type=hidden name=firstname value="<?php $logged_in_author = explode(" ", file_get_contents("data/author.txt")); echo trim(str_replace(",","",$logged_in_author[0])); ?>"></p></td>
  3219. <?php
  3220. }
  3221. elseif (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")) and file_exists("data/members/active/{$_SESSION['logged_in']}") and file_exists("data/bb.txt")) {
  3222. ?>
  3223.         <td width=75><p></p></td><td><input type=hidden name=cauthor value="<?php echo $_SESSION['logged_in']; ?>"><input type=hidden name=firstname value="<?php echo file_get_contents("data/members/active/{$_SESSION['logged_in']}/firstname.txt"); ?>"></p></td>
  3224. <?php
  3225. }
  3226. else {
  3227.  
  3228. ?>
  3229.  
  3230. <td width=75><p>First Name*</p></td><td width=300><input class=input type=text autocomplete=off name=firstname maxlength=30></td>
  3231.  
  3232. <?php
  3233.  
  3234. }
  3235.  
  3236. ?>
  3237.                         <td rowspan=7 valign=top width=75 align=right>
  3238.                         <table border=0 cellspacing=1 cellpadding=2>
  3239.                         <tr><td><img src=images/smileys/crying.png border=0></td><td><p>:((</p></td><td ><p>crying</p></td></tr>
  3240.                         <tr><td><img src=images/smileys/frown.png border=0></td><td><p>:(</p></td><td><p>frown</p></td></tr>
  3241.                         <tr><td><img src=images/smileys/indifferent.png border=0></td><td><p>:|</p></td><td><p>indifferent</p></td></tr>
  3242.                         <tr><td><img src=images/smileys/laughing.png border=0></td><td><p>:D</p></td><td><p>laughing</p></td></tr>
  3243.                         <tr><td><img src=images/smileys/lick.png border=0></td><td><p>:P</p></td><td><p>lick</p></td></tr>
  3244.                         <tr><td><img src=images/smileys/ohno.png border=0></td><td><p>:O</p></td><td><p>oh no!</p></td></tr>
  3245.                         <tr><td><img src=images/smileys/smile.png border=0></td><td><p>:)</p></td><td><p>smile</p></td></tr>
  3246.                         <tr><td><img src=images/smileys/surprised.png border=0></td><td><p>=)</p></td><td><p>surprised</p></td></tr>
  3247.                         <tr><td><img src=images/smileys/undecided.png border=0></td><td><p>:\</p></td><td><p>undecided</p></td></tr>
  3248.                         <tr><td><img src=images/smileys/wink.png border=0></td><td><p>;)</p></td><td><p>wink</p></td></tr>
  3249.                         </td></tr>
  3250.                         </table>
  3251.  
  3252. <?php
  3253. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  3254. ?>
  3255.         <td width=75><p></p></td><td><input type=hidden name=lastname value="<?php echo trim(str_replace(",","",$logged_in_author[1])); ?>"></p></td>
  3256. <?php
  3257. }
  3258. elseif (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")) and file_exists("data/members/active/{$_SESSION['logged_in']}") and file_exists("data/bb.txt")) {
  3259. ?>
  3260.         <td width=75><p></p></td><td><input type=hidden name=lastname value="<?php echo file_get_contents("data/members/active/{$_SESSION['logged_in']}/lastname.txt"); ?>"></p></td>
  3261. <?php
  3262. }
  3263. else {
  3264.  
  3265. ?>
  3266.  
  3267.                         <tr><td><p>Last Name*</p></td><td><input class=input type=text autocomplete=off name=lastname maxlength=30></td></tr>
  3268.  
  3269. <?php
  3270.  
  3271. }
  3272.  
  3273. ?>
  3274.  
  3275. <?php
  3276. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  3277.         if (file_exists("data/email.txt")) {
  3278. ?>
  3279.                 <td width=75><p></p></td><td colspan=2><input type=hidden name=email value="<?php echo file_get_contents("data/email.txt"); ?>"></p></td>
  3280. <?php
  3281.         }
  3282.         else {
  3283.                 echo "<tr><td><p>E-mail*</p></td><td colspan=2><input class=input type=text autocomplete=off name=email maxlength=60></td></tr>";
  3284.         }
  3285. }
  3286. elseif (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")) and file_exists("data/members/active/{$_SESSION['logged_in']}") and file_exists("data/bb.txt")) {
  3287. ?>
  3288.         <td width=75><p></p></td><td colspan=2><input type=hidden name=email value="<?php echo file_get_contents("data/members/active/{$_SESSION['logged_in']}/email.txt"); ?>"></p></td>
  3289. <?php
  3290. }
  3291. else {
  3292.  
  3293. ?>
  3294.  
  3295.                         <tr><td><p>E-mail*</p></td><td colspan=2><input class=input type=text autocomplete=off name=email maxlength=60></td></tr>
  3296.  
  3297. <?php
  3298.  
  3299. }
  3300.  
  3301. ?>
  3302.  
  3303. <?php
  3304. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  3305. ?>
  3306.         <td width=75><p></p></td><td colspan=2><input type=hidden name=url value="<?php file_get_contents("data/url.txt"); ?>"></p></td>
  3307. <?php
  3308. }
  3309. elseif (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")) and file_exists("data/members/active/{$_SESSION['logged_in']}") and file_exists("data/bb.txt")) {
  3310. ?>
  3311.         <td width=75><p></p></td><td colspan=2><input type=hidden name=url value="<?php if (file_exists("data/members/active/{$_SESSION['logged_in']}/url.txt")) { echo file_get_contents("data/members/active/{$_SESSION['logged_in']}/url.txt"); } ?>"></p></td>
  3312. <?php
  3313. }
  3314. else {
  3315.  
  3316. ?>
  3317.  
  3318.                         <tr><td><p>Website</p></td><td colspan=2><input class=input type=text autocomplete=off name=url maxlength=300></td></tr>
  3319.  
  3320. <?php
  3321.  
  3322. }
  3323.  
  3324. ?>
  3325.  
  3326.                         <tr><td><p>Comment*</p></td><td><textarea class=input name=new_comment rows=15></textarea></td></tr>
  3327.                         <?php
  3328.                         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  3329.                                 echo "<input type=hidden name=captcha_put value=\"$captcha_rand\">";
  3330.                         }
  3331.                         else {
  3332.                                 echo "<tr><td><p>Anti-Spam*</p></td><td><input class=input type=text autocomplete=off name=captcha_put maxlength=7></td></tr>";
  3333.                         }
  3334.                         ?>
  3335.  
  3336.                         <tr><td><p></p></td><td><input class=input type=submit value="click here to submit your comment"></td></tr>
  3337.                         </form>
  3338.                         </table>
  3339.                 <?php } ?>
  3340.                 </td></tr></table></p>
  3341.  
  3342. <?php
  3343. }
  3344.  
  3345. if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt") and file_exists("data/members/active/{$_SESSION['logged_in']}")))) {
  3346.         if (isset($_REQUEST['show']) and !empty($_REQUEST['show']) and isset($_POST['captcha_put']) and !empty($_REQUEST['captcha_get']) and isset($_POST['firstname']) and !empty($_POST['firstname']) and isset($_POST['lastname']) and !empty($_POST['lastname']) and isset($_POST['email']) and !empty($_POST['email']) and isset($_POST['new_comment']) and !empty($_POST['new_comment']) and isset($_POST['captcha_put']) and !empty($_POST['captcha_put']) and ($_REQUEST['captcha_get'] == $_POST['captcha_put']) and (ereg("@", $_POST['email'])) and (ereg("\.", $_POST['email']))) {
  3347.                 echo '<p><table border=0 cellspacing=0 cellpadding=0><tr><td><p><font style="font-size: 12px;"><b>Thanks!</b></font></p><p>Your comment has been submitted for approval.<br>Please check back soon to see if it has been posted.</p></td></tr></table></p>';
  3348.         }
  3349. }
  3350.  ?>
  3351.        
  3352.  
  3353.  
  3354.                 <?php
  3355.         }
  3356. }
  3357. ?>
  3358.  
  3359. <?php
  3360. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username) and isset($_REQUEST['entry']) and !empty($_REQUEST['entry'])) {
  3361.         if ($dh_pending_comments = opendir("$dir/$d/comments/pending")) {
  3362.                 while (($entry_pending_comments = readdir($dh_pending_comments)) !== false) {
  3363.                         if ($entry_pending_comments != "." && $entry_pending_comments != ".." && fnmatch("*", $entry_pending_comments)) {
  3364.                                 $show_pending_comments[] = $entry_pending_comments;
  3365.                         }
  3366.                 }
  3367.                 closedir($dh_pending_comments);
  3368.         }
  3369.  
  3370.         asort($show_pending_comments);
  3371.         reset($show_pending_comments);
  3372.         $count_pending_comments = count($show_pending_comments);
  3373.  
  3374.         if ($count_pending_comments > 0) {
  3375.                 if ($count_pending_comments == 1) {
  3376.                         echo '<p><b>Pending Comment</b></p>';
  3377.                 }
  3378.                 else {
  3379.                         echo '<p><b>Pending Comments</b></p>';
  3380.                 }
  3381.                 foreach ($show_pending_comments as $pending_comment) {
  3382.                         echo '<p><table border=0 cellspacing=0 cellpadding=0 width=';
  3383.        
  3384.                         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  3385.                                 echo "610";
  3386.                         }
  3387.                         else {
  3388.                                 echo "525";
  3389.                         }
  3390.  
  3391.                         echo '><tr><td>';
  3392.  
  3393.                         if (file_exists("data/round.txt")) {
  3394.                                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  3395.                         }
  3396.                         else {
  3397.                                 echo '<div id=panel_title>';
  3398.                         }
  3399.  
  3400.                         if (file_exists("$dir/$d/comments/pending/$pending_comment/url.txt")) {
  3401.                                 echo '<a target=_maj href=';
  3402.                                 readfile("$dir/$d/comments/pending/$pending_comment/url.txt");
  3403.                                 echo '>';
  3404.                         }
  3405.        
  3406.                         readfile("$dir/$d/comments/pending/$pending_comment/firstname.txt");
  3407.                         echo ' ';
  3408.                         readfile("$dir/$d/comments/pending/$pending_comment/lastname.txt");
  3409.        
  3410.                         if (file_exists("$dir/$d/comments/pending/$pending_comment/url.txt")) {
  3411.                                 echo '</a>';
  3412.                         }
  3413.        
  3414.                         echo ' &lt;';
  3415.                         readfile("$dir/$d/comments/pending/$pending_comment/email.txt");
  3416.                         echo '&gt;';
  3417.  
  3418.                         echo '<a href=del.php?entry=' . $d . '&comment=' . $pending_comment . '&type=pending><img src=images/widget.del.png width=11 height=11 border=0 align=right alt="delete comment"></a>';
  3419.  
  3420.                         $pending_comment_key_file = "$dir/$d/comments/pending/$pending_comment/key.txt";
  3421.                         $open_pending_comment_key_file = fopen($pending_comment_key_file,"r");
  3422.                         $pending_comment_login_key = fread($open_pending_comment_key_file,filesize($pending_comment_key_file));
  3423.                         fclose($open_pending_comment_key_file);
  3424.  
  3425.                         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&comment=' . $pending_comment . '&key=' . $pending_comment_login_key . '&action=approve><img src=images/widget.cat.png width=11 height=11 border=0 align=right alt="post comment"></a>';
  3426.  
  3427.                         echo '<a href=move.php?entry=' . $d . '&comment=' . $pending_comment . '&type=pending><img src=images/widget.move.png width=11 height=11 border=0 align=right alt="move comment"></a>';
  3428.  
  3429.                         echo '<a href=edit.php?entry=' . $d . '&comment=' . $pending_comment . '&type=pending><img src=images/widget.edit.png width=11 height=11 border=0 align=right alt="edit comment"></a>';
  3430.  
  3431.                         echo '</div><div id=panel_body><table border=0 cellspacing=0 cellpadding=0><tr>';
  3432.  
  3433.                         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt") and file_exists("$dir/$d/comments/pending/$pending_comment/author.txt")) {
  3434.                                 echo "<td width=85 valign=top><p>";
  3435.                                 $pc_author = file_get_contents("$dir/$d/comments/pending/$pending_comment/author.txt");
  3436.                                 echo "<a href=member.php?id=$pc_author>";
  3437.                                 if ((file_get_contents("data/username.txt") == $pc_author) and (file_exists("images/avatar.jpg") or file_exists("images/avatar.gif") or file_exists("images/avatar.png"))) {
  3438.                                         if (file_exists("images/avatar.gif")) {
  3439.                                                 $pc_avatar_gif_image_size = getimagesize("images/avatar.gif");
  3440.                                                 $pc_avatar_gif_image_width = $pc_avatar_gif_image_size[0];
  3441.                                                 $pc_avatar_gif_image_height = $pc_avatar_gif_image_size[1];
  3442.                
  3443.                                                 $pc_max_avatar_gif_image_width = 80;
  3444.                                        
  3445.                                                 if ($pc_avatar_gif_image_width > $pc_max_avatar_gif_image_width) {  
  3446.                                                         $sizefactor = (double) ($pc_max_avatar_gif_image_width / $pc_avatar_gif_image_width) ;
  3447.                                                         $pc_avatar_gif_image_width = (int) ($pc_avatar_gif_image_width * $sizefactor);
  3448.                                                         $pc_avatar_gif_image_height = (int) ($pc_avatar_gif_image_height * $sizefactor);
  3449.                                                 }
  3450.                
  3451.                                                 echo "<img src=images/avatar.gif border=0 width=";
  3452.                                                 echo $pc_avatar_gif_image_width;
  3453.                                                 echo " height=";
  3454.                                                 echo $pc_avatar_gif_image_height;
  3455.                                         }
  3456.                                         if (file_exists("images/avatar.jpg")) {
  3457.                                                 $pc_avatar_jpg_image_size = getimagesize("images/avatar.jpg");
  3458.                                                 $pc_avatar_jpg_image_width = $pc_avatar_jpg_image_size[0];
  3459.                                                 $pc_avatar_jpg_image_height = $pc_avatar_jpg_image_size[1];
  3460.                                        
  3461.                                                 $pc_max_avatar_jpg_image_width = 80;
  3462.                                        
  3463.                                                 if ($pc_avatar_jpg_image_width > $pc_max_avatar_jpg_image_width) {  
  3464.                                                         $sizefactor = (double) ($pc_max_avatar_jpg_image_width / $pc_avatar_jpg_image_width) ;
  3465.                                                         $pc_avatar_jpg_image_width = (int) ($pc_avatar_jpg_image_width * $sizefactor);
  3466.                                                         $pc_avatar_jpg_image_height = (int) ($pc_avatar_jpg_image_height * $sizefactor);
  3467.                                                 }
  3468.                
  3469.                                                 echo "<img src=images/avatar.jpg border=0 width=";
  3470.                                                 echo $pc_avatar_jpg_image_width;
  3471.                                                 echo " height=";
  3472.                                                 echo $pc_avatar_jpg_image_height;
  3473.                                         }
  3474.                                         if (file_exists("images/avatar.png")) {
  3475.                                                 $pc_avatar_png_image_size = getimagesize("images/avatar.png");
  3476.                                                 $pc_avatar_png_image_width = $pc_avatar_png_image_size[0];
  3477.                                                 $pc_avatar_png_image_height = $pc_avatar_png_image_size[1];
  3478.                                        
  3479.                                                 $pc_max_avatar_png_image_width = 80;
  3480.                                        
  3481.                                                 if ($pc_avatar_png_image_width > $pc_max_avatar_png_image_width) {  
  3482.                                                         $sizefactor = (double) ($pc_max_avatar_png_image_width / $pc_avatar_png_image_width) ;
  3483.                                                         $pc_avatar_png_image_width = (int) ($pc_avatar_png_image_width * $sizefactor);
  3484.                                                         $pc_avatar_png_image_height = (int) ($pc_avatar_png_image_height * $sizefactor);
  3485.                                                 }
  3486.                                        
  3487.                                                 echo "<img src=images/avatar.png border=0 width=";
  3488.                                                 echo $pc_avatar_png_image_width;
  3489.                                                 echo " height=";
  3490.                                                 echo $pc_avatar_png_image_height;
  3491.                                         }
  3492.                                 echo "><br>";
  3493.                                 }
  3494.                                 elseif (file_exists("images/members/$pc_author/avatar.jpg") or file_exists("images/members/$pc_author/avatar.gif") or file_exists("images/members/$pc_author/avatar.png")) {
  3495.                                         if (file_exists("images/members/$pc_author/avatar.gif")) {
  3496.                                                 $pc_avatar_gif_image_size = getimagesize("images/members/$pc_author/avatar.gif");
  3497.                                                 $pc_avatar_gif_image_width = $pc_avatar_gif_image_size[0];
  3498.                                                 $pc_avatar_gif_image_height = $pc_avatar_gif_image_size[1];
  3499.                
  3500.                                                 $pc_max_avatar_gif_image_width = 80;
  3501.                                        
  3502.                                                 if ($pc_avatar_gif_image_width > $pc_max_avatar_gif_image_width) {  
  3503.                                                         $sizefactor = (double) ($pc_max_avatar_gif_image_width / $pc_avatar_gif_image_width) ;
  3504.                                                         $pc_avatar_gif_image_width = (int) ($pc_avatar_gif_image_width * $sizefactor);
  3505.                                                         $pc_avatar_gif_image_height = (int) ($pc_avatar_gif_image_height * $sizefactor);
  3506.                                                 }
  3507.                
  3508.                                                 echo "<img src=images/members/$pc_author/avatar.gif border=0 width=";
  3509.                                                 echo $pc_avatar_gif_image_width;
  3510.                                                 echo " height=";
  3511.                                                 echo $pc_avatar_gif_image_height;
  3512.                                         }
  3513.                                         if (file_exists("images/members/$pc_author/avatar.jpg")) {
  3514.                                                 $pc_avatar_jpg_image_size = getimagesize("images/members/$pc_author/avatar.jpg");
  3515.                                                 $pc_avatar_jpg_image_width = $pc_avatar_jpg_image_size[0];
  3516.                                                 $pc_avatar_jpg_image_height = $pc_avatar_jpg_image_size[1];
  3517.                                        
  3518.                                                 $pc_max_avatar_jpg_image_width = 80;
  3519.                                        
  3520.                                                 if ($pc_avatar_jpg_image_width > $pc_max_avatar_jpg_image_width) {  
  3521.                                                         $sizefactor = (double) ($pc_max_avatar_jpg_image_width / $pc_avatar_jpg_image_width) ;
  3522.                                                         $pc_avatar_jpg_image_width = (int) ($pc_avatar_jpg_image_width * $sizefactor);
  3523.                                                         $pc_avatar_jpg_image_height = (int) ($pc_avatar_jpg_image_height * $sizefactor);
  3524.                                                 }
  3525.                
  3526.                                                 echo "<img src=images/members/$pc_author/avatar.jpg border=0 width=";
  3527.                                                 echo $pc_avatar_jpg_image_width;
  3528.                                                 echo " height=";
  3529.                                                 echo $pc_avatar_jpg_image_height;
  3530.                                         }
  3531.                                         if (file_exists("images/members/$pc_author/avatar.png")) {
  3532.                                                 $pc_avatar_png_image_size = getimagesize("images/members/$pc_author/avatar.png");
  3533.                                                 $pc_avatar_png_image_width = $pc_avatar_png_image_size[0];
  3534.                                                 $pc_avatar_png_image_height = $pc_avatar_png_image_size[1];
  3535.                                        
  3536.                                                 $pc_max_avatar_png_image_width = 80;
  3537.                                        
  3538.                                                 if ($pc_avatar_png_image_width > $pc_max_avatar_png_image_width) {  
  3539.                                                         $sizefactor = (double) ($pc_max_avatar_png_image_width / $pc_avatar_png_image_width) ;
  3540.                                                         $pc_avatar_png_image_width = (int) ($pc_avatar_png_image_width * $sizefactor);
  3541.                                                         $pc_avatar_png_image_height = (int) ($pc_avatar_png_image_height * $sizefactor);
  3542.                                                 }
  3543.                                        
  3544.                                                 echo "<img src=images/members/$pc_author/avatar.png border=0 width=";
  3545.                                                 echo $pc_avatar_png_image_width;
  3546.                                                 echo " height=";
  3547.                                                 echo $pc_avatar_png_image_height;
  3548.                                         }
  3549.                                 echo "><br>";
  3550.                                 }
  3551.                                 echo "$pc_author</a><br>";
  3552.                                 if ((file_get_contents("data/username.txt") == $pc_author) and file_exists("data/rank.txt")) {
  3553.                                         echo "administrator<br>";
  3554.                                 }
  3555.                                 elseif (file_exists("data/members/active/$pc_author/rank.txt") and file_exists("data/rank.txt")) {
  3556.                                         $pc_rank = file_get_contents("data/members/active/$pc_author/rank.txt");
  3557.                                         echo "$pc_rank<br>";
  3558.                                 }
  3559.                                 elseif (!file_exists("data/members/active/$pc_author/rank.txt") and file_exists("data/rank.txt")) {
  3560.                                         echo "member<br>";
  3561.                                 }
  3562.                
  3563.                                 if ($pc_dh_posts = opendir("data/items")) {
  3564.                                         while (($pc_entry_posts = readdir($pc_dh_posts)) !== false) {
  3565.                
  3566.                                                 if (file_exists("data/items/$pc_entry_posts/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3567.                                                         continue;
  3568.                                                 }
  3569.                
  3570.                                                 if (file_exists("data/items/$pc_entry_posts/member.txt") and (!isset($_SESSION['logged_in']))) {
  3571.                                                         continue;
  3572.                                                 }
  3573.                
  3574.                                                 $pc_post_cat_dir = file_get_contents("data/items/$pc_entry_posts/category.txt");
  3575.                
  3576.                                                 if (file_exists("data/categories/$pc_post_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$pc_entry_posts/cat.txt")) {
  3577.                                                         continue;
  3578.                                                 }
  3579.                
  3580.                                                 if ($pc_entry_posts != "." && $pc_entry_posts != ".." && fnmatch("*", $pc_entry_posts)) {
  3581.                                                         if (file_exists("data/members/active/$pc_author") and file_exists("data/bb.txt")) {
  3582.                                                                 if (file_exists("data/items/$pc_entry_posts/author.txt") and (file_get_contents("data/items/$pc_entry_posts/author.txt") == $pc_author)) {
  3583.                                                                         $pc_items_posts[] = $pc_entry_posts;
  3584.                                                                 }
  3585.                                                         }
  3586.                                                         elseif (!file_exists("data/members/active/$pc_author") and (file_get_contents("data/username.txt") == $pc_author) and file_exists("data/bb.txt")) {
  3587.                                                                 if (file_exists("data/items/$pc_entry_posts/author.txt") and (file_get_contents("data/items/$pc_entry_posts/author.txt") == $pc_author)) {
  3588.                                                                         $pc_items_posts[] = $pc_entry_posts;
  3589.                                                                 }
  3590.                                                         }
  3591.                                                 }
  3592.                                         }
  3593.                                 closedir($pc_dh_posts);
  3594.                                 }
  3595.                                 $pc_posts = count($pc_items_posts);
  3596.                                 if ($pc_posts == 1) {
  3597.                                         echo "$pc_posts post";
  3598.                                 }
  3599.                                 if ($pc_posts > 1) {
  3600.                                         echo "$pc_posts posts";
  3601.                                 }
  3602.                                 unset($pc_items_posts);
  3603.                
  3604.                                 echo "</p></td><td width=513 valign=top>";
  3605.                         }
  3606.                         else {
  3607.                                 echo "<td width=598 valign=top>";
  3608.                         }
  3609.  
  3610.                         echo '<p><font style="font-size: 10px; color: #999999;">';
  3611.                         if ((file_exists("$dir/$d/comments/pending/$pending_comment/author.txt") and (file_exists("data/bb.txt") and !file_exists("data/avatar.txt")) or (file_exists("$dir/$d/comments/pending/$pending_comment/author.txt") and (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username) and !file_exists("data/avatar.txt"))))) {
  3612.                                 $pxavatar_author = file_get_contents("$dir/$d/comments/pending/$pending_comment/author.txt");
  3613.                                 echo "<a href=member.php?id=$pxavatar_author>$pxavatar_author</a> - ";
  3614.                         }
  3615.                         readfile("$dir/$d/comments/pending/$pending_comment/timestamp.txt");
  3616.  
  3617.                         if (file_exists("$dir/$d/comments/pending/$pending_comment/revisions.txt")) {
  3618.                                 echo '  (Revision ';
  3619.                                 readfile("$dir/$d/comments/pending/$pending_comment/revisions.txt");
  3620.                                 echo ')';
  3621.                         }
  3622.  
  3623.                         echo '</font><font style="font-size: 5px;"><br><br></font>';
  3624.                         readfile("$dir/$d/comments/pending/$pending_comment/comment.txt");
  3625.                         echo '</p></tr></table></div>';
  3626.  
  3627.                         if (file_exists("data/round.txt")) {
  3628.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  3629.                         }
  3630.  
  3631.                         unset($show_pending_comments);
  3632.                         echo '</td></tr></table></p>';
  3633.                 }
  3634.         }
  3635. }
  3636. ?>
  3637.  
  3638. <p><table border=0 cellspacing=0 cellpadding=0 width=100%><tr>
  3639.  
  3640. <?php
  3641. if (($start >= $increase) and ($start != 0)) {
  3642.         echo "<td align=left><p><a href=\"" . $_SERVER['PHP_SELF'] . "?";
  3643.         if (isset($_REQUEST['category']) and !empty($_REQUEST['category']) and file_exists(strip_tags(strtolower(str_replace(" ", "_", "data/categories/{$_REQUEST['category']}"))))) {
  3644.                 echo "category={$_REQUEST['category']}&";
  3645.         }
  3646.         if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  3647.                 echo "archive={$_REQUEST['archive']}&";
  3648.         }
  3649.         if (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and file_exists("data/members/active/{$_REQUEST['author']}") and file_exists("data/bb.txt")) {
  3650.                 echo "author={$_REQUEST['author']}&";
  3651.         }
  3652.         if (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and !file_exists("data/members/active/{$_REQUEST['author']}") and (file_get_contents("data/username.txt") == $_REQUEST['author']) and file_exists("data/bb.txt")) {
  3653.                 echo "author={$_REQUEST['author']}&";
  3654.         }
  3655.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "private")) {
  3656.                 echo "find=private&";
  3657.         }
  3658.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "member")) {
  3659.                 echo "find=member&";
  3660.         }
  3661.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "unfiled")) {
  3662.                 echo "find=unfiled&";
  3663.         }
  3664.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "passwd")) {
  3665.                 echo "find=passwd&";
  3666.         }
  3667.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "comments")) {
  3668.                 echo "find=comments&";
  3669.         }
  3670.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "album")) {
  3671.                 echo "find=album&";
  3672.         }
  3673.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "filedrop")) {
  3674.                 echo "find=filedrop&";
  3675.         }
  3676.         echo "start=" . ($start-$increase) . "\">previous</a></p></td>";
  3677. }
  3678.  
  3679. if ($end < sizeof($items)) {
  3680.         echo "<td align=right><p><a href=\"" . $_SERVER['PHP_SELF'] . "?";
  3681.         if (isset($_REQUEST['category']) and !empty($_REQUEST['category']) and file_exists(strip_tags(strtolower(str_replace(" ", "_", "data/categories/{$_REQUEST['category']}"))))) {
  3682.                 echo "category={$_REQUEST['category']}&";
  3683.         }
  3684.         if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  3685.                 echo "archive={$_REQUEST['archive']}&";
  3686.         }
  3687.         if (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and file_exists("data/members/active/{$_REQUEST['author']}") and file_exists("data/bb.txt")) {
  3688.                 echo "author={$_REQUEST['author']}&";
  3689.         }
  3690.         if (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and !file_exists("data/members/active/{$_REQUEST['author']}") and (file_get_contents("data/username.txt") == $_REQUEST['author']) and file_exists("data/bb.txt")) {
  3691.                 echo "author={$_REQUEST['author']}&";
  3692.         }
  3693.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "private")) {
  3694.                 echo "find=private&";
  3695.         }
  3696.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "member")) {
  3697.                 echo "find=member&";
  3698.         }
  3699.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "unfiled")) {
  3700.                 echo "find=unfiled&";
  3701.         }
  3702.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "passwd")) {
  3703.                 echo "find=passwd&";
  3704.         }
  3705.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "comments")) {
  3706.                 echo "find=comments&";
  3707.         }
  3708.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "album")) {
  3709.                 echo "find=album&";
  3710.         }
  3711.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "filedrop")) {
  3712.                 echo "find=filedrop&";
  3713.         }
  3714.         echo "start=" . ($start+$increase) . "\">next</a></p></td>";
  3715. }
  3716. ?>
  3717.  
  3718. </tr></table></p>
  3719.  
  3720. </td>
  3721.  
  3722. <td width=175 valign=top>
  3723.  
  3724. <?php
  3725. if ($dh_latest_items = opendir($dir)) {
  3726.         while (($entry_latest_items = readdir($dh_latest_items)) !== false) {
  3727.  
  3728.                 if (file_exists("data/items/$entry_latest_items/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3729.                         continue;
  3730.                 }
  3731.  
  3732.                 if (file_exists("data/items/$entry_latest_items/member.txt") and (!isset($_SESSION['logged_in']))) {
  3733.                         continue;
  3734.                 }
  3735.  
  3736.                 $cat_dir = file_get_contents("data/items/$entry_latest_items/category.txt");
  3737.  
  3738.                 if (file_exists("data/categories/$cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_latest_items/cat.txt")) {
  3739.                         continue;
  3740.                 }
  3741.  
  3742.                 if (file_exists("data/nocat.txt") and file_exists("data/items/$entry_latest_items/category.txt") and !file_exists("data/items/$entry_latest_items/cat.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3743.                         continue;
  3744.                 }
  3745.  
  3746.                 if ($entry_latest_items != "." && $entry_latest_items != ".." && fnmatch("*", $entry_latest_items)) {
  3747.                         $show_latest_items[] = $entry_latest_items;
  3748.                 }
  3749.         }
  3750.         closedir($dh_latest_items);
  3751. }
  3752.  
  3753. rsort($show_latest_items);
  3754. reset($show_latest_items);
  3755. $count_latest_items = count($show_latest_items);
  3756.  
  3757. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  3758.         if ($dh_pending_comment_flags = opendir("data/comments/pending")) {
  3759.                 while (($entry_pending_comment_flags = readdir($dh_pending_comment_flags)) !== false) {
  3760.                         if ($entry_pending_comment_flags != "." && $entry_pending_comment_flags != ".." && fnmatch("*", $entry_pending_comment_flags)) {
  3761.                                 $show_pending_comment_flags[] = $entry_pending_comment_flags;
  3762.                         }
  3763.                 }
  3764.                 closedir($dh_pending_comment_flags);
  3765.         }
  3766.  
  3767.         rsort($show_pending_comment_flags);
  3768.         reset($show_pending_comment_flags);
  3769.         $count_pending_comment_flags = count($show_pending_comment_flags);
  3770.  
  3771.         if (($count_latest_items > 0) and ($count_pending_comment_flags > 0)) {
  3772.  
  3773.                 if (file_exists("data/round.txt")) {
  3774.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  3775.                 }
  3776.                 else {
  3777.                         echo '<div id=panel_title>';
  3778.                 }
  3779.  
  3780.                 echo 'Pending Comments</div>';
  3781.                 echo '<div id=panel_body>';
  3782.  
  3783.                 if ($dh_list_pending_comment_flags = opendir("data/comments/pending")) {
  3784.  
  3785.                         while (($entry_list_pending_comment_flags = readdir($dh_list_pending_comment_flags)) !== false) {
  3786.  
  3787.                                 if ($entry_list_pending_comment_flags != "." && $entry_list_pending_comment_flags != ".." && fnmatch("*", $entry_list_pending_comment_flags)) {
  3788.  
  3789.                                         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' .$entry_list_pending_comment_flags . '&show=comments>';
  3790.                                         readfile("data/items/$entry_list_pending_comment_flags/title.txt");
  3791.                                         echo '</a><br><font style="font-size: 10px; color: #999999;">';
  3792.                                         $fp_comment_count_txt = fopen("data/comments/pending/$entry_list_pending_comment_flags/count.txt","r");
  3793.                                         $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$entry_list_pending_comment_flags/count.txt"));
  3794.                                         fclose($fp_comment_count_txt);
  3795.  
  3796.                                         if ($comment_count_value == 1) {
  3797.                                                 echo ' ( ' . $comment_count_value . ' comment ) ';
  3798.                                         }
  3799.                                         elseif ($comment_count_value > 1) {
  3800.                                                 echo ' ( ' . $comment_count_value . ' comments ) ';
  3801.                                         }
  3802.                                         else {
  3803.                                                 echo '';
  3804.                                         }
  3805.                                         echo '</font><br>';
  3806.                                 }
  3807.                         }
  3808.                         closedir($dh_list_pending_comment_flags);
  3809.                 }
  3810.                 echo '</div>';
  3811.  
  3812.                 if (file_exists("data/round.txt")) {
  3813.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  3814.                 }
  3815.         }
  3816. }
  3817.  
  3818. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username) and file_exists("data/members/confirmed") and !file_exists("data/xapp.txt") and file_exists("data/bb.txt") and file_exists("data/reg.txt")) {
  3819.         if ($dh_pending_list = opendir("data/members/confirmed")) {
  3820.                 while (($entry_pending_list = readdir($dh_pending_list)) !== false) {
  3821.  
  3822.                         if ($entry_pending_list != "." && $entry_pending_list != ".." && fnmatch("*", $entry_pending_list)) {
  3823.                                 $show_pending_list[] = $entry_pending_list;
  3824.                         }
  3825.                 }
  3826.                 closedir($dh_pending_list);
  3827.         }
  3828.  
  3829.         sort($show_pending_list);
  3830.         reset($show_pending_list);
  3831.         $count_pending_list = count($show_pending_list);
  3832.        
  3833.         if ($count_pending_list > 0) {
  3834.  
  3835.                 if (file_exists("data/round.txt")) {
  3836.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  3837.                 }
  3838.                 else {
  3839.                         echo '<div id=panel_title>';
  3840.                 }
  3841.  
  3842.                 echo "Pending Member";
  3843.                 if ($count_pending_list > 1) {
  3844.                         echo "s";
  3845.                 }
  3846.                 echo "</div><div id=panel_body>Please approve or deny $count_pending_list pending membership request";
  3847.                 if ($count_pending_list > 1) {
  3848.                         echo "s";
  3849.                 }
  3850.                 echo " below.</div>";
  3851.  
  3852.                 if (file_exists("data/round.txt")) {
  3853.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  3854.                 }
  3855.  
  3856.                 foreach ($show_pending_list as $pending_list_entry) {
  3857.  
  3858.                         if (file_exists("data/round.txt")) {
  3859.                                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  3860.                         }
  3861.                         else {
  3862.                                 echo '<div id=panel_title>';
  3863.                         }
  3864.  
  3865.                         echo "$pending_list_entry";
  3866.                         echo '<a href=reg.php?username=';
  3867.                         echo $pending_list_entry;
  3868.                         echo '&key=';
  3869.                         readfile("data/members/confirmed/$pending_list_entry/key.txt");
  3870.                         echo '&action=deny><img src=images/widget.del.png border=0 width=11 height=11 align=right alt=deny></a><a href=reg.php?username=';
  3871.                         echo $pending_list_entry;
  3872.                         echo '&key=';
  3873.                         readfile("data/members/confirmed/$pending_list_entry/key.txt");
  3874.                         echo '&action=approve><img src=images/widget.cat.png border=0 width=11 height=11 align=right alt=approve></a></div>';
  3875.                         echo "<div id=panel_body>";
  3876.                         if (file_exists("data/members/confirmed/$pending_list_entry/url.txt")) {
  3877.                                 echo "<a href=\"";
  3878.                                 readfile("data/members/confirmed/$pending_list_entry/url.txt");
  3879.                                 echo "\" target=_pending>";
  3880.                         }
  3881.                         readfile("data/members/confirmed/$pending_list_entry/firstname.txt");
  3882.                         echo "&nbsp;";
  3883.                         readfile("data/members/confirmed/$pending_list_entry/lastname.txt");
  3884.                         if (file_exists("data/members/confirmed/$pending_list_entry/url.txt")) {
  3885.                                 echo "</a>";
  3886.                         }
  3887.                         echo "<br>";
  3888.                         $pending_email = file_get_contents("data/members/confirmed/$pending_list_entry/email.txt");
  3889.                         $pending_email = wordwrap($pending_email,30);
  3890.                         echo $pending_email;
  3891.                         if (file_exists("data/members/confirmed/$pending_list_entry/timestamp.txt")) {
  3892.                                 $confirmed = file_get_contents("data/members/confirmed/$pending_list_entry/timestamp.txt");
  3893.                                 $confirmed_year = substr($confirmed,0,4);
  3894.                                 $confirmed_month = substr($confirmed,4,2);
  3895.                                 $confirmed_day = substr($confirmed,6,2);
  3896.                                 $confirmed_hh = substr($confirmed,8,2);
  3897.                                 $confirmed_mm = substr($confirmed,10,2);
  3898.                                 $email_confirmed = date("d M Y H:i", mktime($confirmed_hh, $confirmed_mm, 0, $confirmed_month, $confirmed_day, $confirmed_year));
  3899.                                 echo "<br>$email_confirmed";
  3900.                         }
  3901.                         echo "</div>";
  3902.  
  3903.                         if (file_exists("data/round.txt")) {
  3904.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  3905.                         }
  3906.                 }
  3907.         }
  3908. }
  3909.  
  3910. if (($count_latest_items > 0) and (!file_exists("data/xrecent.txt") or isset($_SESSION['logged_in']))) {
  3911.  
  3912.         if (file_exists("data/round.txt")) {
  3913.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  3914.         }
  3915.         else {
  3916.                 echo '<div id=panel_title>';
  3917.         }
  3918.  
  3919.         echo 'Recent Entries</div><div id=panel_body>';
  3920.  
  3921.         $increment_recent_entries = 0;
  3922.  
  3923.         if (($count_latest_items <= $increase) or ($count_latest_items <= $increase * 2)) {
  3924.                 $increase = $count_latest_items;
  3925.                 $show_recent_entries = $increase - 1;
  3926.         }
  3927.         else {
  3928.                 $show_recent_entries = $increase * 2 - 1;
  3929.         }
  3930.  
  3931.         while ($increment_recent_entries <= $show_recent_entries) {
  3932.                 echo '<a class=navlink href=' . $_SERVER['PHP_SELF'] . '?entry=' . $show_latest_items[$increment_recent_entries] . '>';
  3933.                 readfile("$dir/$show_latest_items[$increment_recent_entries]/title.txt");
  3934.                 echo '</a><br>';
  3935.                 $increment_recent_entries = $increment_recent_entries + 1;
  3936.         }
  3937.  
  3938.         echo '</div>';
  3939.  
  3940.         if (file_exists("data/round.txt")) {
  3941.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  3942.         }
  3943. }
  3944. ?>
  3945.  
  3946. <?php
  3947. if (file_exists("data/bb.txt") and file_exists("data/bb-stats.txt")) {
  3948.  
  3949.         if (file_exists("data/round.txt")) {
  3950.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  3951.         }
  3952.         else {
  3953.                 echo '<div id=panel_title>';
  3954.         }
  3955.  
  3956.         echo "Bulletin Board</div><div id=panel_body>";
  3957.         if (file_exists("data/members/active") and file_exists("data/bb.txt")) {
  3958.                 if ($dh_active_list = opendir("data/members/active")) {
  3959.                         while (($entry_active_list = readdir($dh_active_list)) !== false) {
  3960.                                 if ($entry_active_list != "." && $entry_active_list != ".." && fnmatch("*", $entry_active_list)) {
  3961.                                         $show_active_list[] = $entry_active_list;
  3962.                                 }
  3963.                         }
  3964.                 closedir($dh_active_list);
  3965.                 }
  3966.  
  3967.                 sort($show_active_list);
  3968.                 reset($show_active_list);
  3969.                 $count_active_list = count($show_active_list);
  3970.                 if ($count_active_list > 0) {
  3971.                         echo "Registered Members: $count_active_list";
  3972.                 }
  3973.         }
  3974.  
  3975.  
  3976.         if (file_exists("data/items")) {
  3977.                 if ($dh_mempost_list = opendir("data/items")) {
  3978.                         while (($entry_mempost_list = readdir($dh_mempost_list)) !== false) {
  3979.  
  3980.                                 if (file_exists("data/items/$entry_mempost_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3981.                                         continue;
  3982.                                 }
  3983.  
  3984.                                 // hide_member (20070606)
  3985.                                 //if (file_exists("data/items/$entry_mempost_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  3986.                                 //      continue;
  3987.                                 //}
  3988.  
  3989.                                 $get_cat_dir = file_get_contents("data/items/$entry_mempost_list/category.txt");
  3990.  
  3991.                                 if (file_exists("data/categories/$get_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_mempost_list/cat.txt")) {
  3992.                                         continue;
  3993.                                 }
  3994.        
  3995.                                 if ($entry_mempost_list != "." && $entry_mempost_list != ".." && fnmatch("*", $entry_mempost_list)) {
  3996.                                         $entry_mempost_list = substr("$entry_mempost_list",0,6);
  3997.                                         $show_mempost_list[] = $entry_mempost_list;
  3998.                                 }
  3999.                         }
  4000.                         closedir($dh_mempost_list);
  4001.                 }
  4002.                 rsort($show_mempost_list);
  4003.                 $count_mempost_list = count($show_mempost_list);
  4004.                 echo "<br>Total Posts: $count_mempost_list";
  4005.                 unset($show_mempost_list);
  4006.         }
  4007.  
  4008.         if (file_exists("data/bb-new.txt")) {
  4009.                 $bb_new = file_get_contents("data/bb-new.txt");
  4010.                 echo "<br>Newest User: <a href=member.php?id=$bb_new>$bb_new</a>";
  4011.         }
  4012.         if (file_exists("data/bb-last.txt")) {
  4013.                 $bb_last = file_get_contents("data/bb-last.txt");
  4014.                 echo "<br>Latest Login: <a href=member.php?id=$bb_last>$bb_last</a>";
  4015.         }
  4016.         echo "</div>";
  4017.  
  4018.         if (file_exists("data/round.txt")) {
  4019.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4020.         }
  4021. }
  4022. ?>
  4023.  
  4024. <?php
  4025.  
  4026. if (file_exists("data/round.txt")) {
  4027.         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4028. }
  4029. else {
  4030.         echo '<div id=panel_title>';
  4031. }
  4032.  
  4033. ?>
  4034.  
  4035. Search</div>
  4036. <form enctype="multipart/form-data" action="dig.php" method="post">
  4037. <div id="panel_body">
  4038. <input type="text" class="search" name="search" autocomplete="off" maxlength="55">
  4039. </form>
  4040. </div>
  4041.  
  4042. <?php
  4043.  
  4044. if (file_exists("data/round.txt")) {
  4045.         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4046. }
  4047.  
  4048. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  4049.  
  4050.         if (file_exists("data/round.txt")) {
  4051.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4052.         }
  4053.         else {
  4054.                 echo '<div id=panel_title>';
  4055.         }
  4056.  
  4057.         echo "Find Entries</div><div id=panel_body>";
  4058.         echo "<a class=navlink href=index.php?find=private>Private</a>";
  4059.         if (file_exists("data/bb.txt")) {
  4060.                 echo "<br><a class=navlink href=index.php?find=member>Members-Only</a>";
  4061.         }
  4062.         echo "<br><a class=navlink href=index.php?find=unfiled>Unfiled</a>";
  4063.         echo "<br><a class=navlink href=index.php?find=passwd>Password Protected</a>";
  4064.         echo "<br><a class=navlink href=index.php?find=comments>With Comments</a>";
  4065.         echo "<br><a class=navlink href=index.php?find=filedrop>With Attached Files</a>";
  4066.         echo "<br><a class=navlink href=index.php?find=album>With Photo Album</a>";
  4067.         echo "</div>";
  4068.  
  4069.         if (file_exists("data/round.txt")) {
  4070.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4071.         }
  4072. }
  4073. ?>
  4074.  
  4075. <?php
  4076. if (file_exists("data/categories")) {
  4077.         if ($dh_categories = opendir("data/categories")) {
  4078.                 while (($entry_categories = readdir($dh_categories)) !== false) {
  4079.  
  4080.                         if (file_exists("data/xcat.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4081.                                 continue;
  4082.                         }
  4083.  
  4084.                         if (file_exists("data/categories/$entry_categories/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4085.                                 continue;
  4086.                         }
  4087.  
  4088.                         if ($entry_categories != "." && $entry_categories != ".." && fnmatch("*", $entry_categories)) {
  4089.                                 $show_categories[] = $entry_categories;
  4090.                         }
  4091.                 }
  4092.                 closedir($dh_categories);
  4093.         }
  4094.  
  4095.         sort($show_categories);
  4096.         reset($show_categories);
  4097.         $count_categories = count($show_categories);
  4098.  
  4099.         if ($count_categories > 0) {
  4100.  
  4101.                 if (file_exists("data/round.txt")) {
  4102.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4103.                 }
  4104.                 else {
  4105.                         echo '<div id=panel_title>';
  4106.                 }
  4107.  
  4108.                 echo 'Categories</div><div id=panel_body>';
  4109.                 foreach ($show_categories as $category) {
  4110.                         echo "<a class=navlink href=\"" . $_SERVER['PHP_SELF'] . "?category=" . $category . "\">";
  4111.                         if (file_exists("data/categories/$category/title.txt")) {
  4112.                                 $category_title = file_get_contents("data/categories/$category/title.txt");
  4113.                         }
  4114.                         else {
  4115.                                 $category_title = ucfirst(str_replace("_"," ",$category));
  4116.                         }
  4117.                         echo $category_title;
  4118.                         echo "</a><br />";
  4119.                 }
  4120.                 echo '</div>';
  4121.  
  4122.                 if (file_exists("data/round.txt")) {
  4123.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4124.                 }
  4125.         }
  4126. }
  4127.  
  4128. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  4129.  
  4130.         if (file_exists("data/round.txt")) {
  4131.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4132.         }
  4133.         else {
  4134.                 echo '<div id=panel_title>';
  4135.         }
  4136.  
  4137.         echo 'Statistics</div><div id=panel_body>';
  4138.         echo "Total Entries: $count_latest_items";
  4139.         if (file_exists("data/hits.txt")) {
  4140.                 echo '<br>Site Hits: ';
  4141.                 readfile("data/hits.txt");
  4142.         }
  4143.         if (file_exists("data/google.txt")) {
  4144.                 echo '<br>Google Visits: ';
  4145.                 readfile("data/google.txt");
  4146.         }
  4147.         if (file_exists("data/rss-0.91.txt")) {
  4148.                 echo '<br>RSS 0.91 Hits: ';
  4149.                 readfile("data/rss-0.91.txt");
  4150.         }
  4151.         if (file_exists("data/rss-1.0.txt")) {
  4152.                 echo '<br>RSS 1.0 Hits: ';
  4153.                 readfile("data/rss-1.0.txt");
  4154.         }
  4155.         if (file_exists("data/rss-2.0.txt")) {
  4156.                 echo '<br>RSS 2.0 Hits: ';
  4157.                 readfile("data/rss-2.0.txt");
  4158.         }
  4159.         if (file_exists("data/sitemap.txt")) {
  4160.                 echo '<br>Sitemap Requests: ';
  4161.                 readfile("data/sitemap.txt");
  4162.         }
  4163.  
  4164.         echo '</div>';
  4165.  
  4166.         if (file_exists("data/round.txt")) {
  4167.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4168.         }
  4169. }
  4170.  
  4171. ?>
  4172.  
  4173. <?php
  4174. if (file_exists("data/albums")) {
  4175.         if ($dh_album_list = opendir("data/albums")) {
  4176.                 while (($entry_album_list = readdir($dh_album_list)) !== false) {
  4177.  
  4178.                         if (file_exists("data/items/$entry_album_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4179.                                 continue;
  4180.                         }
  4181.  
  4182.                         if (file_exists("data/items/$entry_album_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  4183.                                 continue;
  4184.                         }
  4185.  
  4186.                         $pull_cat_dir = file_get_contents("data/items/$entry_album_list/category.txt");
  4187.  
  4188.                         if (file_exists("data/categories/$pull_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_album_list/cat.txt")) {
  4189.                                 continue;
  4190.                         }
  4191.  
  4192.                         if ($entry_album_list != "." && $entry_album_list != ".." && fnmatch("*", $entry_album_list)) {
  4193.                                 $show_album_list[] = $entry_album_list;
  4194.                         }
  4195.                 }
  4196.                 closedir($dh_album_list);
  4197.         }
  4198.  
  4199.         rsort($show_album_list);
  4200.         reset($show_album_list);
  4201.         $count_album_list = count($show_album_list);
  4202.        
  4203.         if ($count_album_list > 0) {
  4204.  
  4205.                 if (file_exists("data/round.txt")) {
  4206.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4207.                 }
  4208.                 else {
  4209.                         echo '<div id=panel_title>';
  4210.                 }
  4211.  
  4212.                 echo 'Albums</div>';
  4213.                 echo '<div id=panel_body>';
  4214.                 foreach ($show_album_list as $album_list_entry) {
  4215.                         echo '<a class=navlink href=' . $_SERVER['PHP_SELF'] . '?entry=';
  4216.                         echo $album_list_entry;
  4217.                         echo '&show=album>';
  4218.                         readfile("data/items/$album_list_entry/title.txt");
  4219.                         echo '</a><br>';
  4220.                 }
  4221.                 echo '</div>';
  4222.  
  4223.                 if (file_exists("data/round.txt")) {
  4224.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4225.                 }
  4226.         }
  4227. }
  4228. ?>
  4229.  
  4230.  
  4231. <?php
  4232.  
  4233. if (!file_exists("data/xrand.txt")) {
  4234.  
  4235.         if ($dh_random_post_items = opendir($dir)) {
  4236.                 while (($entry_random_post_items = readdir($dh_random_post_items)) !== false) {
  4237.        
  4238.                         if (file_exists("data/items/$entry_random_post_items/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4239.                                 continue;
  4240.                         }
  4241.        
  4242.                         $cat_dir = file_get_contents("data/items/$entry_random_post_items/category.txt");
  4243.        
  4244.                         if (file_exists("data/categories/$cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_random_post_items/cat.txt")) {
  4245.                                 continue;
  4246.                         }
  4247.        
  4248.                         if ($entry_random_post_items != "." && $entry_random_post_items != ".." && fnmatch("*", $entry_random_post_items)) {
  4249.                                 $show_random_post_items[] = $entry_random_post_items;
  4250.                         }
  4251.                 }
  4252.                 closedir($dh_random_post_items);
  4253.         }
  4254.        
  4255.         shuffle($show_random_post_items);
  4256.         reset($show_random_post_items);
  4257.         $count_random_post_items = count($show_random_post_items);
  4258.        
  4259.         if (file_exists("data/increase.txt")) {
  4260.                 $limit_random_post_entries = file_get_contents("data/increase.txt");
  4261.         }
  4262.         else {
  4263.                 $limit_random_post_entries = 5;
  4264.         }
  4265.        
  4266.         if ($count_random_post_items > $limit_random_post_entries) {
  4267.        
  4268.                 if (file_exists("data/round.txt")) {
  4269.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4270.                 }
  4271.                 else {
  4272.                         echo '<div id=panel_title>';
  4273.                 }
  4274.        
  4275.                 echo "Random Entries</div><div id=panel_body>";
  4276.        
  4277.                 $increment_random_post_entries = 0;
  4278.        
  4279.                 if ($count_random_post_items <= $limit_random_post_entries * 2) {
  4280.                         $show_random_post_entries = $count_random_post_items - 1;
  4281.                 }
  4282.                 else {
  4283.                         $show_random_post_entries = $limit_random_post_entries * 2 - 1;
  4284.                 }
  4285.        
  4286.                 while ($increment_random_post_entries <= $show_random_post_entries) {
  4287.                         echo "<a class=navlink href=index.php?entry={$show_random_post_items[$increment_random_post_entries]}>";
  4288.                         readfile("$dir/$show_random_post_items[$increment_random_post_entries]/title.txt");
  4289.                         echo "</a><br>";
  4290.        
  4291.                         $increment_random_post_entries = $increment_random_post_entries + 1;
  4292.                 }
  4293.         }
  4294.        
  4295.         if ($count_random_post_items > 0) {
  4296.                 echo "</div>";
  4297.        
  4298.                 if (file_exists("data/round.txt")) {
  4299.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4300.                 }
  4301.         }
  4302. }
  4303. ?>
  4304.  
  4305.  
  4306. <?php
  4307. if (file_exists("data/items")) {
  4308.         if ($dh_archive_list = opendir("data/items")) {
  4309.                 while (($entry_archive_list = readdir($dh_archive_list)) !== false) {
  4310.  
  4311.                         if (file_exists("data/xarc.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4312.                                 continue;
  4313.                         }
  4314.  
  4315.                         if (file_exists("data/items/$entry_archive_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4316.                                 continue;
  4317.                         }
  4318.  
  4319.                         // hide member
  4320.                         //if (file_exists("data/items/$entry_archive_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  4321.                         //      continue;
  4322.                         //}
  4323.  
  4324.                         $get_cat_dir = file_get_contents("data/items/$entry_archive_list/category.txt");
  4325.  
  4326.                         if (file_exists("data/categories/$get_cat_dir/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) and !file_exists("data/items/$entry_archive_list/cat.txt")) {
  4327.                                 continue;
  4328.                         }
  4329.  
  4330.                         if ($entry_archive_list != "." && $entry_archive_list != ".." && fnmatch("*", $entry_archive_list)) {
  4331.                                 $entry_archive_list = substr("$entry_archive_list",0,6);
  4332.                                 $show_archive_list[] = $entry_archive_list;
  4333.                         }
  4334.                 }
  4335.                 closedir($dh_archive_list);
  4336.         }
  4337.  
  4338.         rsort($show_archive_list);
  4339.         reset($show_archive_list);
  4340.         $count_archive_list = count($show_archive_list);
  4341.        
  4342.         if (($count_archive_list > 0) and ($count_latest_items > 0)) {
  4343.  
  4344.                 $archive_entries = implode(" ",$show_archive_list);
  4345.                 $unique_archive_list = array_unique($show_archive_list);
  4346.  
  4347.                 if (file_exists("data/round.txt")) {
  4348.                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4349.                 }
  4350.                 else {
  4351.                         echo '<div id=panel_title>';
  4352.                 }
  4353.  
  4354.                 echo "Archives ($count_archive_list)</div>";
  4355.                 echo "<div id=\"panel_body\"><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" width=\"100%\">";
  4356.                 foreach ($unique_archive_list as $archive_list_entry) {
  4357.                         $archive_list_value = substr($archive_list_entry,0,6);
  4358.                         $archive_list_year = substr($archive_list_entry,0,4);
  4359.                         $archive_list_month = substr($archive_list_entry,4,2);
  4360.                         $archive_list_month = date("F",mktime(0,0,0,$archive_list_month));
  4361.                         $archive_list_num = substr_count($archive_entries,$archive_list_entry);
  4362.                         echo "<tr><td><a class=navlink href=\"index.php?archive=$archive_list_value\"><nobr>$archive_list_month $archive_list_year</nobr></a></td><td align=right>$archive_list_num</td></tr>";
  4363.                 }
  4364.                 echo "</table></div>";
  4365.  
  4366.                 if (file_exists("data/round.txt")) {
  4367.                         echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4368.                 }
  4369.         }
  4370. }
  4371.  
  4372. ?>
  4373.  
  4374.  
  4375. <?php
  4376.  
  4377. if (file_exists("data/clustrmaps.php")) {
  4378.  
  4379.         if (file_exists("data/round.txt")) {
  4380.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4381.         }
  4382.         else {
  4383.                 echo '<div id=panel_title>';
  4384.         }
  4385.  
  4386.         echo 'ClustrMaps</div>';
  4387.         echo '<div id=panel_body><center>';
  4388.         include("data/clustrmaps.php");
  4389.         echo '</center></div>';
  4390.  
  4391.         if (file_exists("data/round.txt")) {
  4392.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4393.         }
  4394. }
  4395. ?>
  4396.  
  4397. <?php
  4398.  
  4399. if (file_exists("data/adsense.php")) {
  4400.  
  4401.         if (file_exists("data/round.txt")) {
  4402.                 echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4403.         }
  4404.         else {
  4405.                 echo '<div id=panel_title>';
  4406.         }
  4407.  
  4408.         echo 'AdSense</div>';
  4409.         echo '<div id=panel_body><center>';
  4410.         include("data/adsense.php");   
  4411.         echo '</center></div>';
  4412.  
  4413.         if (file_exists("data/round.txt")) {
  4414.                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4415.         }
  4416. }
  4417. ?>
  4418.  
  4419. <?php
  4420. if (file_exists("data/panels")) {
  4421.         if ($dh_right_panel_list = opendir("data/panels")) {
  4422.                 while (($entry_right_panel_list = readdir($dh_right_panel_list)) !== false) {
  4423.  
  4424.                         if (file_exists("data/panels/$entry_right_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  4425.                                 continue;
  4426.                         }
  4427.  
  4428.                         if (!file_exists("data/panels/$entry_right_panel_list/right.txt")) {
  4429.                                 continue;
  4430.                         }
  4431.  
  4432.                         if ($entry_right_panel_list != "." && $entry_right_panel_list != ".." && fnmatch("*", $entry_right_panel_list)) {
  4433.                                 $show_right_panel_list[] = $entry_right_panel_list;
  4434.                         }
  4435.                 }
  4436.                 closedir($dh_right_panel_list);
  4437.         }
  4438.  
  4439.         sort($show_right_panel_list);
  4440.         reset($show_right_panel_list);
  4441.         $count_right_panel_list = count($show_right_panel_list);
  4442.        
  4443.         if ($count_right_panel_list > 0) {
  4444.                 foreach ($show_right_panel_list as $right_panel_list_entry) {
  4445.                         if (!file_exists("data/panels/$right_panel_list_entry/free.txt")) {
  4446.  
  4447.                                 if (file_exists("data/round.txt")) {
  4448.                                         echo '<b class="rbtop"><b class="rb1t"></b><b class="rb2t"></b><b class="rb3t"></b><b class="rb4t"></b></b><div class="xtitle">';
  4449.                                 }
  4450.                                 else {
  4451.                                         echo '<div id=panel_title>';
  4452.                                 }
  4453.  
  4454.                                 readfile("data/panels/$right_panel_list_entry/title.txt");
  4455.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  4456.                                         echo "<a href=panels.php#{$right_panel_list_entry}>";
  4457.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  4458.                                 }
  4459.                                 echo '</div><div id=panel_body>';
  4460.                         }
  4461.                         if (file_exists("data/panels/$right_panel_list_entry/free.txt")) {
  4462.                                 echo '<div id=panel_free>';
  4463.                         }
  4464.                         include("data/panels/$right_panel_list_entry/panel.php");
  4465.                         echo '</div>';
  4466.  
  4467.                         if (file_exists("data/round.txt") and !file_exists("data/panels/$right_panel_list_entry/free.txt")) {
  4468.                                 echo '<b class="rbbottom"><b class="rb4b"></b><b class="rb3b"></b><b class="rb2b"></b><b class="rb1b"></b></b>';
  4469.                         }
  4470.                 }
  4471.         }
  4472. }
  4473. ?>
  4474.  
  4475. <?php
  4476.  
  4477. if ($count_latest_items > 0) {
  4478.         echo '<p><table border=0 cellspacing=2 cellpadding=0 width=100%>';
  4479.         echo '<tr><td align=center><a target="_button" href="http://maj.sourceforge.net/"><img src=images/button.maj.png border=0 width=80 height=15></a></td></tr>';
  4480.         echo '<tr><td align=center><a target="_button" href="http://php.net/"><img src=images/button.php.png border=0 width=80 height=15></a></td></tr>';
  4481.         $validate_uri = $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/";
  4482.         $validate_uri = str_replace('//', '/', $validate_uri);
  4483.         $validate_uri = "http://" . $validate_uri;
  4484.         echo '<tr><td align=center><a target="_button" href="http://jigsaw.w3.org/css-validator/validator?uri=' . $validate_uri . '"><img src=images/button.w3c.css.png border=0 width=80 height=15></a></td></tr>';
  4485.         echo '<tr><td align=center><a target="_button" href="rss.php?ver=0.91"><img src=images/button.rss-0.91.png border=0 width=80 height=15></a></td></tr>';
  4486.         echo '<tr><td align=center><a target="_button" href="rss.php?ver=1.0"><img src=images/button.rss-1.0.png border=0 width=80 height=15></a></td></tr>';
  4487.         echo '<tr><td align=center><a target="_button" href="rss.php?ver=2.0"><img src=images/button.rss-2.0.png border=0 width=80 height=15></a></td></tr>';
  4488.         echo '<tr><td align=center><a target="_button" href="sitemap.php"><img src=images/button.sitemap.png border=0 width=80 height=15></a></td></tr>';
  4489.         if (file_exists("data/sfx.txt")) {
  4490.                 $fp_sfx = fopen("data/sfx.txt", "r");
  4491.                 $sfx = fread($fp_sfx, filesize("data/sfx.txt"));
  4492.                 fclose($fp_sfx);
  4493.                 echo '<tr><td align=center><a target="_button" href="http://www.spreadfirefox.com/?q=affiliates&amp;id=' . $sfx . '&amp;t=85"><img src=images/button.firefox.png border=0 width=80 height=15></a></td></tr>';
  4494.         }
  4495.         echo '</table></p>';
  4496.  
  4497. }
  4498.  
  4499. ?>
  4500.  
  4501. <p></p>
  4502.  
  4503. </td></tr>
  4504. </table>
  4505.  
  4506. <?php
  4507. if (file_exists("footer.php")) {
  4508.         include("footer.php");
  4509. }
  4510.  
  4511. if (file_exists("data/center.txt")) {
  4512.         echo "</center>";
  4513. }
  4514.  
  4515. ?>
  4516.  
filedropmaj.git-01822e4.tar.bz2
147.95 KB
63 downloads
filedropmaj.git-01822e4.zip
201.96 KB
20 downloads
filedropmaj.git-0291349.tar.bz2
152.85 KB
61 downloads
filedropmaj.git-0291349.zip
211.90 KB
20 downloads
filedropmaj.git-02cb3b7.tar.bz2
151.48 KB
64 downloads
filedropmaj.git-02cb3b7.zip
209.82 KB
20 downloads
filedropmaj.git-0811dd5.tar.bz2
152.90 KB
60 downloads
filedropmaj.git-0811dd5.zip
211.90 KB
18 downloads
filedropmaj.git-083625f.tar.bz2
132.92 KB
59 downloads
filedropmaj.git-083625f.zip
179.59 KB
20 downloads
filedropmaj.git-0885d7b.tar.bz2
92.63 KB
60 downloads
filedropmaj.git-0885d7b.zip
132.34 KB
17 downloads
filedropmaj.git-09c6f33.tar.bz2
151.51 KB
59 downloads
filedropmaj.git-09c6f33.zip
202.12 KB
18 downloads
filedropmaj.git-0b26a85.tar.bz2
151.44 KB
57 downloads
filedropmaj.git-0b26a85.zip
209.75 KB
16 downloads
filedropmaj.git-0b32424.tar.bz2
151.66 KB
58 downloads
filedropmaj.git-0b32424.zip
206.72 KB
17 downloads
filedropmaj.git-0f3ac59.tar.bz2
152.14 KB
57 downloads
filedropmaj.git-0f3ac59.zip
211.45 KB
13 downloads
filedropmaj.git-11d4582.tar.bz2
143.02 KB
55 downloads
filedropmaj.git-11d4582.zip
195.12 KB
12 downloads
filedropmaj.git-17f105a.tar.bz2
137.96 KB
53 downloads
filedropmaj.git-17f105a.zip
193.02 KB
13 downloads
filedropmaj.git-183270b.tar.bz2
137.54 KB
57 downloads
filedropmaj.git-183270b.zip
187.93 KB
13 downloads
filedropmaj.git-197a49d.tar.bz2
152.03 KB
55 downloads
filedropmaj.git-197a49d.zip
211.32 KB
16 downloads
filedropmaj.git-1b9af25.tar.bz2
152.87 KB
53 downloads
filedropmaj.git-1b9af25.zip
211.96 KB
14 downloads
filedropmaj.git-1be2914.tar.bz2
149.30 KB
55 downloads
filedropmaj.git-1be2914.zip
203.09 KB
13 downloads
filedropmaj.git-1bed800.tar.bz2
138.15 KB
51 downloads
filedropmaj.git-1bed800.zip
190.15 KB
17 downloads
filedropmaj.git-1d330de.tar.bz2
151.65 KB
54 downloads
filedropmaj.git-1d330de.zip
210.80 KB
15 downloads
filedropmaj.git-1df190d.tar.bz2
151.72 KB
55 downloads
filedropmaj.git-1df190d.zip
210.85 KB
13 downloads
filedropmaj.git-1ee1167.tar.bz2
151.52 KB
56 downloads
filedropmaj.git-1ee1167.zip
202.16 KB
14 downloads
filedropmaj.git-2057838.tar.bz2
151.76 KB
52 downloads
filedropmaj.git-2057838.zip
202.36 KB
14 downloads
filedropmaj.git-2075213.tar.bz2
155.81 KB
52 downloads
filedropmaj.git-2075213.zip
208.39 KB
13 downloads
filedropmaj.git-211b7b0.tar.bz2
142.53 KB
55 downloads
filedropmaj.git-211b7b0.zip
194.64 KB
14 downloads
filedropmaj.git-2331f5a.tar.bz2
75.55 KB
55 downloads
filedropmaj.git-2331f5a.zip
100.32 KB
16 downloads
filedropmaj.git-25e3c4c.tar.bz2
147.57 KB
53 downloads
filedropmaj.git-25e3c4c.zip
201.46 KB
13 downloads
filedropmaj.git-2622313.tar.bz2
151.47 KB
50 downloads
filedropmaj.git-2622313.zip
206.44 KB
12 downloads
filedropmaj.git-273e4b2.tar.bz2
152.60 KB
52 downloads
filedropmaj.git-273e4b2.zip
203.40 KB
15 downloads
filedropmaj.git-2753e51.tar.bz2
136.37 KB
55 downloads
filedropmaj.git-2753e51.zip
184.34 KB
12 downloads
filedropmaj.git-2c1a589.tar.bz2
155.89 KB
49 downloads
filedropmaj.git-2c1a589.zip
208.69 KB
13 downloads
filedropmaj.git-2c3d544.tar.bz2
151.33 KB
51 downloads
filedropmaj.git-2c3d544.zip
206.23 KB
14 downloads
filedropmaj.git-2c85f72.tar.bz2
143.23 KB
50 downloads
filedropmaj.git-2c85f72.zip
194.84 KB
12 downloads
filedropmaj.git-2dc622c.tar.bz2
151.76 KB
48 downloads
filedropmaj.git-2dc622c.zip
202.35 KB
14 downloads
filedropmaj.git-2fabf8a.tar.bz2
151.35 KB
53 downloads
filedropmaj.git-2fabf8a.zip
206.24 KB
15 downloads
filedropmaj.git-322736b.tar.bz2
137.81 KB
45 downloads
filedropmaj.git-322736b.zip
190.18 KB
13 downloads
filedropmaj.git-374279c.tar.bz2
137.54 KB
46 downloads
filedropmaj.git-374279c.zip
189.58 KB
12 downloads
filedropmaj.git-37e852d.tar.bz2
151.32 KB
42 downloads
filedropmaj.git-37e852d.zip
206.21 KB
11 downloads
filedropmaj.git-38636de.tar.bz2
147.35 KB
42 downloads
filedropmaj.git-38636de.zip
201.16 KB
69 downloads
filedropmaj.git-3b25d71.tar.bz2
147.88 KB
35 downloads
filedropmaj.git-3b25d71.zip
201.85 KB
14 downloads
filedropmaj.git-3b6df7a.tar.bz2
153.39 KB
33 downloads
filedropmaj.git-3b6df7a.zip
204.55 KB
17 downloads
filedropmaj.git-3bf6bd2.tar.bz2
137.77 KB
38 downloads
filedropmaj.git-3bf6bd2.zip
190.16 KB
14 downloads
filedropmaj.git-3e012ff.tar.bz2
152.83 KB
34 downloads
filedropmaj.git-3e012ff.zip
211.89 KB
16 downloads
filedropmaj.git-4129ab8.tar.bz2
135.86 KB
42 downloads
filedropmaj.git-4129ab8.zip
184.30 KB
14 downloads
filedropmaj.git-414dbb4.tar.bz2
91.09 KB
40 downloads
filedropmaj.git-414dbb4.zip
130.29 KB
14 downloads
filedropmaj.git-43755d0.tar.bz2
150.25 KB
33 downloads
filedropmaj.git-43755d0.zip
204.44 KB
14 downloads
filedropmaj.git-4c20005.tar.bz2
55.59 KB
37 downloads
filedropmaj.git-4c20005.zip
74.20 KB
14 downloads
filedropmaj.git-4ccdbcd.tar.bz2
136.38 KB
38 downloads
filedropmaj.git-4ccdbcd.zip
185.22 KB
16 downloads
filedropmaj.git-4cd1a1c.tar.bz2
155.25 KB
35 downloads
filedropmaj.git-4cd1a1c.zip
207.88 KB
16 downloads
filedropmaj.git-4cf16d1.tar.bz2
76.32 KB
38 downloads
filedropmaj.git-4cf16d1.zip
101.80 KB
12 downloads
filedropmaj.git-4ec45a0.tar.bz2
131.16 KB
35 downloads
filedropmaj.git-4ec45a0.zip
172.66 KB
14 downloads
filedropmaj.git-4f73c22.tar.bz2
134.46 KB
35 downloads
filedropmaj.git-4f73c22.zip
182.45 KB
13 downloads
filedropmaj.git-5457969.tar.bz2
155.21 KB
38 downloads
filedropmaj.git-5457969.zip
207.63 KB
14 downloads
filedropmaj.git-57ee8a1.tar.bz2
145.49 KB
38 downloads
filedropmaj.git-57ee8a1.zip
198.12 KB
66 downloads
filedropmaj.git-592978d.tar.bz2
138.38 KB
36 downloads
filedropmaj.git-592978d.zip
190.58 KB
13 downloads
filedropmaj.git-5935b42.tar.bz2
135.60 KB
34 downloads
filedropmaj.git-5935b42.zip
183.28 KB
15 downloads
filedropmaj.git-5b443b6.tar.bz2
152.00 KB
36 downloads
filedropmaj.git-5b443b6.zip
211.07 KB
13 downloads
filedropmaj.git-5b4a9bf.tar.bz2
155.29 KB
34 downloads
filedropmaj.git-5b4a9bf.zip
207.93 KB
12 downloads
filedropmaj.git-5b6c01d.tar.bz2
147.13 KB
35 downloads
filedropmaj.git-5b6c01d.zip
200.86 KB
16 downloads
filedropmaj.git-5da45f7.tar.bz2
147.27 KB
36 downloads
filedropmaj.git-5da45f7.zip
201.02 KB
13 downloads
filedropmaj.git-5e53618.tar.bz2
75.57 KB
38 downloads
filedropmaj.git-5e53618.zip
100.78 KB
14 downloads
filedropmaj.git-5f8ca35.tar.bz2
136.39 KB
33 downloads
filedropmaj.git-5f8ca35.zip
185.32 KB
13 downloads
filedropmaj.git-61e3d7b.tar.bz2
153.52 KB
33 downloads
filedropmaj.git-61e3d7b.zip
204.73 KB
15 downloads
filedropmaj.git-62a635c.tar.bz2
155.90 KB
37 downloads
filedropmaj.git-62a635c.zip
208.73 KB
14 downloads
filedropmaj.git-6390d34.tar.bz2
138.39 KB
37 downloads
filedropmaj.git-6390d34.zip
190.56 KB
17 downloads
filedropmaj.git-649dfbe.tar.bz2
151.78 KB
37 downloads
filedropmaj.git-649dfbe.zip
210.91 KB
14 downloads
filedropmaj.git-65d6570.tar.bz2
151.63 KB
39 downloads
filedropmaj.git-65d6570.zip
210.80 KB
16 downloads
filedropmaj.git-660433f.tar.bz2
151.67 KB
36 downloads
filedropmaj.git-660433f.zip
206.68 KB
14 downloads
filedropmaj.git-6619ae5.tar.bz2
153.23 KB
47 downloads
filedropmaj.git-6619ae5.zip
204.28 KB
13 downloads
filedropmaj.git-68e4e3a.tar.bz2
135.13 KB
34 downloads
filedropmaj.git-68e4e3a.zip
182.91 KB
13 downloads
filedropmaj.git-6995297.tar.bz2
144.93 KB
38 downloads
filedropmaj.git-6995297.zip
197.18 KB
12 downloads
filedropmaj.git-69d6fd3.tar.bz2
143.23 KB
34 downloads
filedropmaj.git-69d6fd3.zip
194.89 KB
16 downloads
filedropmaj.git-6aa872a.tar.bz2
142.95 KB
39 downloads
filedropmaj.git-6aa872a.zip
195.11 KB
15 downloads
filedropmaj.git-6bad5c7.tar.bz2
147.04 KB
38 downloads
filedropmaj.git-6bad5c7.zip
200.79 KB
14 downloads
filedropmaj.git-6e96a2d.tar.bz2
152.13 KB
37 downloads
filedropmaj.git-6e96a2d.zip
207.21 KB
67 downloads
filedropmaj.git-73d46de.tar.bz2
138.42 KB
36 downloads
filedropmaj.git-73d46de.zip
190.59 KB
13 downloads
filedropmaj.git-75e0478.tar.bz2
144.54 KB
38 downloads
filedropmaj.git-75e0478.zip
196.70 KB
15 downloads
filedropmaj.git-784fc35.tar.bz2
143.07 KB
38 downloads
filedropmaj.git-784fc35.zip
195.01 KB
13 downloads
filedropmaj.git-7872a83.tar.bz2
138.51 KB
39 downloads
filedropmaj.git-7872a83.zip
190.69 KB
13 downloads
filedropmaj.git-788fb89.tar.bz2
138.30 KB
37 downloads
filedropmaj.git-788fb89.zip
191.26 KB
18 downloads
filedropmaj.git-796d8a3.tar.bz2
138.92 KB
35 downloads
filedropmaj.git-796d8a3.zip
191.24 KB
13 downloads
filedropmaj.git-79a5e8d.tar.bz2
132.43 KB
38 downloads
filedropmaj.git-79a5e8d.zip
176.90 KB
14 downloads
filedropmaj.git-7b3b2e0.tar.bz2
147.24 KB
36 downloads
filedropmaj.git-7b3b2e0.zip
201.05 KB
14 downloads
filedropmaj.git-7e28eed.tar.bz2
138.89 KB
33 downloads
filedropmaj.git-7e28eed.zip
191.24 KB
14 downloads
filedropmaj.git-8279296.tar.bz2
135.56 KB
38 downloads
filedropmaj.git-8279296.zip
183.25 KB
14 downloads
filedropmaj.git-84c17fe.tar.bz2
152.87 KB
38 downloads
filedropmaj.git-84c17fe.zip
211.90 KB
14 downloads
filedropmaj.git-87c5d5f.tar.bz2
135.78 KB
36 downloads
filedropmaj.git-87c5d5f.zip
183.64 KB
12 downloads
filedropmaj.git-8a48901.tar.bz2
147.27 KB
39 downloads
filedropmaj.git-8a48901.zip
201.06 KB
14 downloads
filedropmaj.git-8ad9892.tar.bz2
164.04 KB
36 downloads
filedropmaj.git-8ad9892.zip
224.42 KB
13 downloads
filedropmaj.git-8b4cf2a.tar.bz2
134.06 KB
37 downloads
filedropmaj.git-8b4cf2a.zip
180.78 KB
14 downloads
filedropmaj.git-8b7e38d.tar.bz2
138.04 KB
41 downloads
filedropmaj.git-8b7e38d.zip
190.39 KB
70 downloads
filedropmaj.git-8df6e40.tar.bz2
143.11 KB
38 downloads
filedropmaj.git-8df6e40.zip
194.66 KB
18 downloads
filedropmaj.git-8e80c84.tar.bz2
138.18 KB
36 downloads
filedropmaj.git-8e80c84.zip
190.30 KB
14 downloads
filedropmaj.git-8ec0fba.tar.bz2
138.37 KB
39 downloads
filedropmaj.git-8ec0fba.zip
191.39 KB
14 downloads
filedropmaj.git-8f7abf6.tar.bz2
153.36 KB
38 downloads
filedropmaj.git-8f7abf6.zip
211.80 KB
13 downloads
filedropmaj.git-923f11a.tar.bz2
138.14 KB
36 downloads
filedropmaj.git-923f11a.zip
191.03 KB
15 downloads
filedropmaj.git-955e82e.tar.bz2
42.71 KB
35 downloads
filedropmaj.git-955e82e.zip
59.77 KB
14 downloads
filedropmaj.git-95add4a.tar.bz2
151.23 KB
40 downloads
filedropmaj.git-95add4a.zip
205.91 KB
14 downloads
filedropmaj.git-96fe0ba.tar.bz2
137.68 KB
32 downloads
filedropmaj.git-96fe0ba.zip
190.34 KB
13 downloads
filedropmaj.git-99a90ce.tar.bz2
137.82 KB
39 downloads
filedropmaj.git-99a90ce.zip
191.20 KB
16 downloads
filedropmaj.git-9a69bb9.tar.bz2
143.19 KB
39 downloads
filedropmaj.git-9a69bb9.zip
194.70 KB
15 downloads
filedropmaj.git-9b6538e.tar.bz2
151.45 KB
36 downloads
filedropmaj.git-9b6538e.zip
202.15 KB
13 downloads
filedropmaj.git-9c4292d.tar.bz2
132.06 KB
37 downloads
filedropmaj.git-9c4292d.zip
176.93 KB
13 downloads
filedropmaj.git-9c78d40.tar.bz2
137.70 KB
37 downloads
filedropmaj.git-9c78d40.zip
190.49 KB
15 downloads
filedropmaj.git-9f1363f.tar.bz2
43.12 KB
40 downloads
filedropmaj.git-9f1363f.zip
60.31 KB
13 downloads
filedropmaj.git-a16c3eb.tar.bz2
90.22 KB
34 downloads
filedropmaj.git-a16c3eb.zip
128.62 KB
14 downloads
filedropmaj.git-a3aa72d.tar.bz2
153.00 KB
37 downloads
filedropmaj.git-a3aa72d.zip
203.86 KB
16 downloads
filedropmaj.git-a6886e4.tar.bz2
144.69 KB
37 downloads
filedropmaj.git-a6886e4.zip
196.95 KB
13 downloads
filedropmaj.git-a8669dc.tar.bz2
135.60 KB
35 downloads
filedropmaj.git-a8669dc.zip
183.34 KB
14 downloads
filedropmaj.git-a9477f1.tar.bz2
135.59 KB
37 downloads
filedropmaj.git-a9477f1.zip
183.45 KB
14 downloads
filedropmaj.git-aa285db.tar.bz2
151.73 KB
38 downloads
filedropmaj.git-aa285db.zip
210.85 KB
14 downloads
filedropmaj.git-aa6ae87.tar.bz2
135.44 KB
37 downloads
filedropmaj.git-aa6ae87.zip
183.88 KB
14 downloads
filedropmaj.git-ab6bc22.tar.bz2
151.71 KB
33 downloads
filedropmaj.git-ab6bc22.zip
210.84 KB
16 downloads
filedropmaj.git-adef726.tar.bz2
153.48 KB
36 downloads
filedropmaj.git-adef726.zip
212.32 KB
14 downloads
filedropmaj.git-afe5877.tar.bz2
144.73 KB
32 downloads
filedropmaj.git-afe5877.zip
197.01 KB
13 downloads
filedropmaj.git-b2d9f8e.tar.bz2
133.22 KB
35 downloads
filedropmaj.git-b2d9f8e.zip
179.27 KB
13 downloads
filedropmaj.git-b41f320.tar.bz2
151.56 KB
33 downloads
filedropmaj.git-b41f320.zip
209.85 KB
18 downloads
filedropmaj.git-b4432ce.tar.bz2
152.96 KB
34 downloads
filedropmaj.git-b4432ce.zip
203.86 KB
14 downloads
filedropmaj.git-b67b08f.tar.bz2
151.27 KB
36 downloads
filedropmaj.git-b67b08f.zip
206.15 KB
16 downloads
filedropmaj.git-b899831.tar.bz2
143.12 KB
35 downloads
filedropmaj.git-b899831.zip
194.60 KB
14 downloads
filedropmaj.git-b8b49c1.tar.bz2
132.59 KB
33 downloads
filedropmaj.git-b8b49c1.zip
178.90 KB
13 downloads
filedropmaj.git-b9c5bcf.tar.bz2
155.92 KB
34 downloads
filedropmaj.git-b9c5bcf.zip
208.70 KB
12 downloads
filedropmaj.git-bbddb1f.tar.bz2
151.63 KB
33 downloads
filedropmaj.git-bbddb1f.zip
209.92 KB
16 downloads
filedropmaj.git-bcaa744.tar.bz2
146.98 KB
37 downloads
filedropmaj.git-bcaa744.zip
200.79 KB
15 downloads
filedropmaj.git-c1ff9dc.tar.bz2
138.39 KB
38 downloads
filedropmaj.git-c1ff9dc.zip
191.43 KB
97 downloads
filedropmaj.git-c20c4b0.tar.bz2
151.64 KB
35 downloads
filedropmaj.git-c20c4b0.zip
210.79 KB
13 downloads
filedropmaj.git-c37f3f7.tar.bz2
145.45 KB
49 downloads
filedropmaj.git-c37f3f7.zip
198.11 KB
22 downloads
filedropmaj.git-c532394.tar.bz2
146.39 KB
37 downloads
filedropmaj.git-c532394.zip
199.91 KB
15 downloads
filedropmaj.git-c6317a4.tar.bz2
152.01 KB
36 downloads
filedropmaj.git-c6317a4.zip
207.08 KB
13 downloads
filedropmaj.git-c748176.tar.bz2
89.44 KB
34 downloads
filedropmaj.git-c748176.zip
126.35 KB
14 downloads
filedropmaj.git-c9ed81f.tar.bz2
135.56 KB
34 downloads
filedropmaj.git-c9ed81f.zip
183.28 KB
16 downloads
filedropmaj.git-c9f9b80.tar.bz2
138.50 KB
34 downloads
filedropmaj.git-c9f9b80.zip
190.66 KB
15 downloads
filedropmaj.git-ca65b73.tar.bz2
152.69 KB
35 downloads
filedropmaj.git-ca65b73.zip
207.87 KB
15 downloads
filedropmaj.git-cd80b77.tar.bz2
153.12 KB
35 downloads
filedropmaj.git-cd80b77.zip
212.01 KB
12 downloads
filedropmaj.git-cffbb2a.tar.bz2
138.22 KB
33 downloads
filedropmaj.git-cffbb2a.zip
190.28 KB
14 downloads
filedropmaj.git-d061ad7.tar.bz2
55.78 KB
47 downloads
filedropmaj.git-d061ad7.zip
74.39 KB
15 downloads
filedropmaj.git-d0af4d6.tar.bz2
57.28 KB
35 downloads
filedropmaj.git-d0af4d6.zip
78.56 KB
15 downloads
filedropmaj.git-d1caa0a.tar.bz2
144.57 KB
37 downloads
filedropmaj.git-d1caa0a.zip
196.63 KB
14 downloads
filedropmaj.git-d5679b5.tar.bz2
152.37 KB
34 downloads
filedropmaj.git-d5679b5.zip
207.52 KB
15 downloads
filedropmaj.git-d72f459.tar.bz2
147.90 KB
36 downloads
filedropmaj.git-d72f459.zip
201.92 KB
13 downloads
filedropmaj.git-d958c91.tar.bz2
144.67 KB
37 downloads
filedropmaj.git-d958c91.zip
196.88 KB
17 downloads
filedropmaj.git-d96784f.tar.bz2
135.58 KB
36 downloads
filedropmaj.git-d96784f.zip
183.46 KB
12 downloads
filedropmaj.git-da4b73f.tar.bz2
152.62 KB
33 downloads
filedropmaj.git-da4b73f.zip
203.48 KB
13 downloads
filedropmaj.git-dd24240.tar.bz2
138.27 KB
33 downloads
filedropmaj.git-dd24240.zip
190.45 KB
72 downloads
filedropmaj.git-e11e772.tar.bz2
152.09 KB
33 downloads
filedropmaj.git-e11e772.zip
211.33 KB
14 downloads
filedropmaj.git-e61478e.tar.bz2
135.95 KB
37 downloads
filedropmaj.git-e61478e.zip
183.91 KB
14 downloads
filedropmaj.git-e7a2547.tar.bz2
133.80 KB
33 downloads
filedropmaj.git-e7a2547.zip
180.05 KB
16 downloads
filedropmaj.git-e8a3b95.tar.bz2
138.15 KB
37 downloads
filedropmaj.git-e8a3b95.zip
191.04 KB
12 downloads
filedropmaj.git-eac86d5.tar.bz2
155.65 KB
33 downloads
filedropmaj.git-eac86d5.zip
208.28 KB
12 downloads
filedropmaj.git-ed83bf9.tar.bz2
135.16 KB
34 downloads
filedropmaj.git-ed83bf9.zip
182.91 KB
15 downloads
filedropmaj.git-ee50d40.tar.bz2
135.59 KB
36 downloads
filedropmaj.git-ee50d40.zip
183.48 KB
16 downloads
filedropmaj.git-efdb4df.tar.bz2
155.87 KB
36 downloads
filedropmaj.git-efdb4df.zip
208.72 KB
14 downloads
filedropmaj.git-f1554f8.tar.bz2
151.30 KB
37 downloads
filedropmaj.git-f1554f8.zip
206.22 KB
16 downloads
filedropmaj.git-f72a07b.tar.bz2
153.44 KB
37 downloads
filedropmaj.git-f72a07b.zip
212.11 KB
17 downloads
filedropmaj.git-f7ea5a1.tar.bz2
147.46 KB
36 downloads
filedropmaj.git-f7ea5a1.zip
201.32 KB
17 downloads
filedropmaj.git-f8a7353.tar.bz2
138.49 KB
36 downloads
filedropmaj.git-f8a7353.zip
190.66 KB
18 downloads
filedropmaj.git-fb84a8d.tar.bz2
137.61 KB
41 downloads
filedropmaj.git-fb84a8d.zip
190.70 KB
18 downloads
filedropmaj.git-fdcf5d3.tar.bz2
152.34 KB
40 downloads
filedropmaj.git-fdcf5d3.zip
207.53 KB
17 downloads
filedropmaj.git-feca42d.tar.bz2
132.90 KB
39 downloads
filedropmaj.git-feca42d.zip
179.44 KB
20 downloads