maj.world

maj.world

Git

This blob has been accessed 454 times via Git panel.

  1. <?php
  2.  
  3. ini_set("session.use_trans_sid", 0);
  4.  
  5. session_start();
  6. header("Cache-control: private");
  7.  
  8. error_reporting(E_ERROR);
  9.  
  10. if (get_magic_quotes_gpc()) {
  11.         function stripslashes_array($data) {
  12.                 if (is_array($data)){
  13.                          foreach ($data as $key => $value){
  14.                                   $data[$key] = stripslashes_array($value);
  15.                          }
  16.                          return $data;
  17.                 }
  18.                 else{
  19.                          return stripslashes($data);
  20.                 }
  21.         }
  22.  
  23.         $_REQUEST = stripslashes_array($_REQUEST);
  24. }
  25.  
  26. $dir = "data/items";
  27.  
  28. $default_title = file_get_contents("data/title.txt");
  29.  
  30.  
  31. if (file_exists("data/offset.txt")) {
  32.         $offset = file_get_contents("data/offset.txt");
  33. }
  34. else {
  35.         $offset = 0;
  36. }
  37.  
  38. if (file_exists("data/increase.txt")) {
  39.         $increase = file_get_contents("data/increase.txt");
  40. }
  41. else {
  42.         $increase = 5;
  43. }
  44.  
  45. $default_blog_title = "My Activity Journal";
  46. $default_username = "maj";
  47. $default_password = "php";
  48. $default_blog_profile = "This cool site is powered by <a href=http://engels.mortega.net/index.php?entry=20050521000019 target=_maj>My Activity Journal</a>, a dead-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.";
  49. $default_blog_author = "My Activity Journal";
  50.  
  51. if (!file_exists("data")) {
  52.         mkdir("data");
  53. }
  54.  
  55. if (!file_exists("data/.htaccess")) {
  56.         $htaccess = "Order deny,allow\nDeny from all";
  57.         $fp_htaccess_txt = fopen("data/.htaccess","w");
  58.         fwrite($fp_htaccess_txt, $htaccess);
  59.         fclose($fp_htaccess_txt);
  60. }
  61.  
  62. if (!file_exists("data/title.txt")) {
  63.         $fp_default_title_txt = fopen("data/title.txt","w");
  64.         fwrite($fp_default_title_txt, $default_blog_title);
  65.         fclose($fp_default_title_txt);
  66. }
  67.  
  68. if (!file_exists("data/username.txt")) {
  69.         $fp_htaccess_txt = fopen("data/username.txt","w");
  70.         fwrite($fp_htaccess_txt, $default_username);
  71.         fclose($fp_htaccess_txt);
  72. }
  73.  
  74. if (!file_exists("data/password.txt")) {
  75.         $default_password = sha1($default_password);
  76.         $default_password = md5($default_password);
  77.         $default_password = crypt($default_password, $default_password);
  78.         $fp_htaccess_txt = fopen("data/password.txt","w");
  79.         fwrite($fp_htaccess_txt, $default_password);
  80.         fclose($fp_htaccess_txt);
  81. }
  82.  
  83. if (!file_exists("data/profile.php")) {
  84.         $fp_default_profile_txt = fopen("data/profile.php","w");
  85.         fwrite($fp_default_profile_txt, $default_blog_profile);
  86.         fclose($fp_default_profile_txt);
  87. }
  88.  
  89. if (!file_exists("data/author.txt")) {
  90.         $fp_default_author_txt = fopen("data/author.txt","w");
  91.         fwrite($fp_default_author_txt, $default_blog_author);
  92.         fclose($fp_default_author_txt);
  93. }
  94.  
  95. $login_username = file_get_contents("data/username.txt");
  96.  
  97. if ((!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  98.         $global_hits_file = fopen("data/hits.txt", "r");
  99.         $global_hits_count = fread($global_hits_file, filesize("data/hits.txt"));
  100.         fclose($global_hits_file);
  101.         $global_hits_count = $global_hits_count + 1;
  102.         $global_hits_file = fopen("data/hits.txt", "w");
  103.         fwrite($global_hits_file, $global_hits_count);
  104.         fclose($global_hits_file);
  105. }
  106.  
  107. $agent = $_SERVER['HTTP_USER_AGENT'];
  108.  
  109. if (@ereg("Google", $agent)) {
  110.         $google_hits_file = fopen("data/google.txt", "r");
  111.         $google_hits_count = fread($google_hits_file, filesize("data/google.txt"));
  112.         fclose($google_hits_file);
  113.         $google_hits_count = $google_hits_count + 1;
  114.         $google_hits_file = fopen("data/google.txt", "w");
  115.         fwrite($google_hits_file, $google_hits_count);
  116.         fclose($google_hits_file);
  117. }
  118.  
  119. function str_rand($length = 8, $seeds = 'abcdefghijklmnopqrstuvwxyz0123456789')
  120. {
  121.     $str = '';
  122.     $seeds_count = strlen($seeds);
  123.  
  124.     list($usec, $sec) = explode(' ', microtime());
  125.     $seed = (float) $sec + ((float) $usec * 100000);
  126.     mt_srand($seed);
  127.  
  128.     for ($i = 0; $length > $i; $i++) {
  129.         $str .= $seeds{mt_rand(0, $seeds_count - 1)};
  130.     }
  131.  
  132.     return $str;
  133. }
  134.  
  135. function rmdirr($recurse_dirname)
  136. {
  137.  
  138.     if (!file_exists($recurse_dirname)) {
  139.         return false;
  140.     }
  141.  
  142.     if (is_file($recurse_dirname)) {
  143.         return unlink($recurse_dirname);
  144.     }
  145.  
  146.     $recurse_dir = dir($recurse_dirname);
  147.     while (false !== $recurse_entry = $recurse_dir->read()) {
  148.  
  149.         if ($recurse_entry == '.' || $recurse_entry == '..') {
  150.             continue;
  151.         }
  152.  
  153.         rmdirr("$recurse_dirname/$recurse_entry");
  154.     }
  155.  
  156.     $recurse_dir->close();
  157.     return rmdir($recurse_dirname);
  158. }
  159.  
  160. if (isset($_REQUEST['download']) and !empty($_REQUEST['download'])) {
  161.         ini_set('zlib.output_compression','off');
  162.         $file = str_replace('../','', @$_REQUEST['download']);
  163.         go_download($file);
  164.         die();
  165. }
  166.  
  167. function go_download($dl_file) {
  168.         $d = $_REQUEST['entry'];
  169.  
  170.         if (isset($_REQUEST['type']) and !empty($_REQUEST['type']) and ($_REQUEST['type'] == pdf)) {
  171.                 $dl_path = "data/items/$d/pdf/file";
  172.                 $count_path = "data/items/$d/pdf/count";
  173.                 $count_file = "dl.txt";
  174.         }
  175.         if (isset($_REQUEST['type']) and !empty($_REQUEST['type']) and ($_REQUEST['type'] == filedrop)) {
  176.                 $dl_path = "data/items/$d/filedrop/files";
  177.                 $count_path = "data/items/$d/filedrop/count";
  178.                 $count_file = "{$dl_file}.txt";
  179.         }      
  180.  
  181.         header("Cache-Control: ");
  182.         header("Pragma: ");
  183.         header("Content-type: application/octet-stream");
  184.         header("Content-Disposition: attachment; filename=\"" . $dl_file . "\"");
  185.         header("Content-length: " . filesize("$dl_path/$dl_file"));
  186.         $get_it = fopen("$dl_path/$dl_file", 'rb');
  187.  
  188.         while (!feof($get_it)) {
  189.                 $buf = fread($get_it, 4096);
  190.                 echo $buf;
  191.                 $bytes_sent+=strlen($buf);
  192.         }
  193.  
  194.         if ($bytes_sent==filesize("$dl_path/$dl_file")) {
  195.  
  196.                 if (!file_exists($count_path)) {
  197.                         mkdir($count_path);
  198.                 }
  199.  
  200.                 $unique_downloads = "$count_path/$count_file";
  201.                 $fp_unique_downloads = fopen($unique_downloads, "r");
  202.                 $count_unique_downloads = fread($fp_unique_downloads, filesize($unique_downloads));
  203.                 fclose($fp_unique_downloads);
  204.                 $count_unique_downloads = $count_unique_downloads + 1;
  205.                 $fp_unique_downloads = fopen($unique_downloads, "w");
  206.                 fwrite($fp_unique_downloads, $count_unique_downloads);
  207.                 fclose($fp_unique_downloads);
  208.         }
  209. }
  210.  
  211. 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'])) {
  212.                 $comment_dir = 'data/items/' . $_REQUEST['entry'] .'/comments/pending/' . $_REQUEST['comment'];
  213.                 $key_file = $comment_dir . '/key.txt';
  214.                 $open_key_file = fopen($key_file,"r");
  215.                 $login_key = fread($open_key_file,filesize($key_file));
  216.                 fclose($open_key_file);
  217.  
  218.                 if ($_REQUEST['key'] == $login_key) {
  219.                         if ($_REQUEST['action'] == "approve") {
  220.                                 $live_dir = "data/items/{$_REQUEST['entry']}/comments/live/{$_REQUEST['comment']}";
  221.                                 rename($comment_dir, $live_dir);
  222.                                 unlink("$live_dir/key.txt");
  223.  
  224.                                 $cat_dir = file_get_contents("data/items/{$_REQUEST['entry']}/category.txt");
  225.  
  226.                                 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")) {
  227.  
  228.                                         if (file_exists("data/ml-reply2.txt")) {
  229.                                                 $ml_reply2 = file_get_contents("data/ml-reply2.txt");
  230.                                         }
  231.  
  232.                                         $ml_from = file_get_contents("$live_dir/email.txt");
  233.                                         $ml_from = str_replace(" at ","@",$ml_from);
  234.  
  235.                                         $ml_subject = file_get_contents("data/items/{$_REQUEST['entry']}/title.txt");
  236.                                         if (file_exists("data/ml-prepend.txt")) {
  237.                                                 $ml_subject = file_get_contents("data/ml-prepend.txt") . " " . $ml_subject;
  238.                                         }
  239.                                         $ml_subject = "Re: " . $ml_subject;
  240.  
  241.                                         $ml_mailer = 'MAJ/0.14 (PHP/' . phpversion() . ')';
  242.                                         $ml_body = file_get_contents("$live_dir/comment.txt");
  243.                                         $ml_body = str_replace('<br />', "\n", $ml_body);
  244.                                         $ml_body = str_replace('<img src=images/smileys/crying.png border=0>', ':((', $ml_body);
  245.                                         $ml_body = str_replace('<img src=images/smileys/frown.png border=0>', ':(', $ml_body);
  246.                                         $ml_body = str_replace('<img src=images/smileys/indifferent.png border=0>', ':|', $ml_body);
  247.                                         $ml_body = str_replace('<img src=images/smileys/laughing.png border=0>', ':D', $ml_body);
  248.                                         $ml_body = str_replace('<img src=images/smileys/lick.png border=0>', ':P', $ml_body);
  249.                                         $ml_body = str_replace('<img src=images/smileys/ohno.png border=0>', ':O', $ml_body);
  250.                                         $ml_body = str_replace('<img src=images/smileys/smile.png border=0>', ':)', $ml_body);
  251.                                         $ml_body = str_replace('<img src=images/smileys/surprised.png border=0>', '=)', $ml_body);
  252.                                         $ml_body = str_replace('<img src=images/smileys/undecided.png border=0>', ':\\', $ml_body);
  253.                                         $ml_body = str_replace('<img src=images/smileys/wink.png border=0>', ';)', $ml_body);
  254.  
  255.                                         if (file_exists("data/pf.txt") and file_exists("data/pf-badwords.txt")) {
  256.                                                 $badwords = file_get_contents("data/pf-badwords.txt");
  257.                                                 if (file_exists("data/pf-censor.txt")) {
  258.                                                         $censor = file_get_contents("data/pf-censor.txt");
  259.                                                 }
  260.                                                 else {
  261.                                                         $censor = "[expletive]";
  262.                                                 }
  263.                                                 $ml_body = preg_replace("/\b($badwords)\b/i",$censor,$ml_body);
  264.                                         }
  265.  
  266.                                         if (file_exists("data/ml-header.txt")) {
  267.                                                 $ml_header = file_get_contents("data/ml-header.txt");
  268.                                                 $ml_body = $ml_header . "\n\n" . $ml_body;
  269.                                         }
  270.  
  271.                                         $ml_url = $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/";
  272.                                         $ml_url = str_replace('//', '/', $ml_url);
  273.                                         $ml_url = "http://" . $ml_url . "index.php?entry={$_REQUEST['entry']}&show=comments";
  274.  
  275.                                         $ml_body = $ml_body . "\n\nPlease visit the following URL for the full thread:\n\n" . $ml_url;
  276.  
  277.                                         if (file_exists("data/ml-footer.txt")) {
  278.                                                 $ml_footer = file_get_contents("data/ml-footer.txt");
  279.                                                 $ml_body = $ml_body . "\n\n" . $ml_footer;
  280.                                         }
  281.  
  282.  
  283.                                         if ($dh_ml_member = opendir("data/members/active")) {
  284.                                                 while (($ml_member = readdir($dh_ml_member)) !== false) {
  285.                                                         if ($ml_member != "." && $ml_member != ".." && fnmatch("*", $ml_member)) {
  286.  
  287.                                                                 if (file_exists("data/members/active/$ml_member/noml.txt")) {
  288.                                                                         continue;
  289.                                                                 }
  290.  
  291.                                                                 if (file_exists("data/members/active/$ml_member/vacation.txt")) {
  292.                                                                         continue;
  293.                                                                 }
  294.  
  295.                                                                 $ml_to = file_get_contents("data/members/active/$ml_member/email.txt");
  296.  
  297.                                                                 if (file_exists("data/ml-reply2.txt")) {
  298.                                                                         mail($ml_to, $ml_subject, $ml_body,
  299.                                                                         "From: $ml_from\r\n" .
  300.                                                                         "Reply-To: $ml_reply2\r\n" .
  301.                                                                         "X-Mailer: $ml_mailer");
  302.                                                                 }
  303.                                                                 else {
  304.                                                                         mail($ml_to, $ml_subject, $ml_body,
  305.                                                                         "From: $ml_from\r\n" .
  306.                                                                         "X-Mailer: $ml_mailer");
  307.                                                                 }
  308.                                                         }
  309.                                                 }
  310.                                                 closedir($dh_ml_member);
  311.                                         }
  312.                                 }
  313.  
  314.                         }
  315.                         if ($_REQUEST['action'] == "delete") {
  316.                                 rmdirr($comment_dir);
  317.                         }
  318.                         $pending_comment_flag_dir = $_REQUEST['entry'];
  319.                         $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag_dir/count.txt","r");
  320.                         $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$pending_comment_flag_dir/count.txt"));
  321.                         fclose($fp_comment_count_txt);
  322.                         if ($comment_count_value <= 1) {
  323.                                 rmdirr("data/comments/pending/$pending_comment_flag_dir");
  324.                         }
  325.                         else {
  326.                                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag_dir/count.txt","r");
  327.                                 $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$pending_comment_flag_dir/count.txt"));
  328.                                 fclose($fp_comment_count_txt);
  329.                                 $comment_count_value = $comment_count_value - 1;
  330.                                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag_dir/count.txt","w");
  331.                                 fwrite($fp_comment_count_txt, $comment_count_value);
  332.                                 fclose($fp_comment_count_txt);
  333.                         }
  334.  
  335.                         header("Location: http://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . '?entry=' . $_REQUEST['entry'] . '&show=comments');
  336.                 }
  337. }
  338.  
  339. if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry'])) {
  340.         $check = $dir . '/' . $_REQUEST['entry'];
  341.  
  342.         if (file_exists("$check")) {
  343.                 $filter = $_REQUEST['entry'];
  344.                 echo '<title>';
  345.                 $title = $check . '/title.txt';
  346.                 readfile($title);
  347.                 echo '</title>';
  348.                 $views = $check . '/views.txt';
  349.                 if ((!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  350.                         $fp_views = fopen($views, "r");
  351.                         $count_views = fread($fp_views, filesize($views));
  352.                         fclose($fp_views);
  353.                         $count_views = $count_views + 1;
  354.                         $fp_views = fopen($views, "w");
  355.                         fwrite($fp_views, $count_views);
  356.                         fclose($fp_views);
  357.                 }
  358.                
  359.                 if (isset($_REQUEST['show']) and !empty($_REQUEST['show']) and isset($_REQUEST['captcha_put']) and !empty($_REQUEST['captcha_get']) and isset($_REQUEST['firstname']) and !empty($_REQUEST['firstname']) and isset($_REQUEST['lastname']) and !empty($_REQUEST['lastname']) and isset($_REQUEST['email']) and !empty($_REQUEST['email']) and isset($_REQUEST['new_comment']) and !empty($_REQUEST['new_comment']) and isset($_REQUEST['captcha_put']) and !empty($_REQUEST['captcha_put']) and ($_REQUEST['captcha_get'] == $_REQUEST['captcha_put']) and (ereg("@", $_REQUEST['email'])) and (ereg("\.", $_REQUEST['email']))) {
  360.                
  361.                 if (!file_exists("$check/comments")) {
  362.                         mkdir("$check/comments");
  363.                 }
  364.                 if (!file_exists("$check/comments/pending")) {
  365.                         mkdir("$check/comments/pending");
  366.                 }
  367.  
  368.                 if (!file_exists("$check/comments/live")) {
  369.                         mkdir("$check/comments/live");
  370.                 }
  371.  
  372.                 // GNU date format
  373.                 //$timestamp = date("D M j H:i:s \P\H\T Y", time() + $offset);
  374.  
  375.                 // Simple PHP Blog format
  376.                 $timestamp = date("l, M j, Y, g:i A", time() + $offset);
  377.  
  378.                 $comment_entry_dir = date("YmdHis", time() + $offset);
  379.  
  380.                 mkdir("$check/comments/pending/$comment_entry_dir");
  381.  
  382.                 $body_content = ucfirst($_REQUEST['new_comment']);
  383.                 $body_content = htmlentities($body_content, ENT_NOQUOTES);
  384.                 // $body_content = str_replace('href=', 'target=_maj href=', $body_content);
  385.                 $body_content = str_replace("\n", '<br />', $body_content);
  386.                 $body_content = trim($body_content);
  387.  
  388.                 $body_content = str_replace(':((', '<img src=images/smileys/crying.png border=0>', $body_content);
  389.  
  390.                 $body_content = str_replace(':(', '<img src=images/smileys/frown.png border=0>', $body_content);
  391.  
  392.                 $body_content = str_replace(':|', '<img src=images/smileys/indifferent.png border=0>', $body_content);
  393.  
  394.                 $body_content = str_replace(':D', '<img src=images/smileys/laughing.png border=0>', $body_content);
  395.  
  396.                 $body_content = str_replace(':P', '<img src=images/smileys/lick.png border=0>', $body_content);
  397.  
  398.                 $body_content = str_replace(':O', '<img src=images/smileys/ohno.png border=0>', $body_content);
  399.  
  400.                 $body_content = str_replace(':)', '<img src=images/smileys/smile.png border=0>', $body_content);
  401.  
  402.                 $body_content = str_replace('=)', '<img src=images/smileys/surprised.png border=0>', $body_content);
  403.  
  404.                 $body_content = str_replace(':\\', '<img src=images/smileys/undecided.png border=0>', $body_content);
  405.  
  406.                 $body_content = str_replace(';)', '<img src=images/smileys/wink.png border=0>', $body_content);
  407.  
  408.                 $fp_body_txt = fopen("$check/comments/pending/$comment_entry_dir/comment.txt","w");
  409.                 fwrite($fp_body_txt,$body_content);
  410.                 fclose($fp_body_txt);
  411.  
  412.                 $fp_timestamp_txt = fopen("$check/comments/pending/$comment_entry_dir/timestamp.txt","w");
  413.                 fwrite($fp_timestamp_txt,$timestamp);
  414.                 fclose($fp_timestamp_txt);
  415.  
  416.                 $fp_firstname_txt = fopen("$check/comments/pending/$comment_entry_dir/firstname.txt","w");
  417.                 $firstname = strtolower($_REQUEST['firstname']);
  418.                 $firstname = ucwords($firstname);
  419.                 $firstname = trim($firstname);
  420.                 $firstname = htmlentities($firstname, ENT_NOQUOTES);
  421.                 fwrite($fp_firstname_txt,$firstname);
  422.                 fclose($fp_firstname_txt);
  423.  
  424.                 $fp_lastname_txt = fopen("$check/comments/pending/$comment_entry_dir/lastname.txt","w");
  425.                 $lastname = strtolower($_REQUEST['lastname']);
  426.                 $lastname = ucwords($lastname);
  427.                 $lastname = trim($lastname);
  428.                 $lastname = htmlentities($lastname, ENT_NOQUOTES);
  429.                 fwrite($fp_lastname_txt,$lastname);
  430.                 fclose($fp_lastname_txt);
  431.  
  432.                 $fp_email_txt = fopen("$check/comments/pending/$comment_entry_dir/email.txt","w");
  433.                 $email = str_replace('@', ' at ', $_REQUEST['email']);
  434.                 $email = strtolower($email);
  435.                 $email = trim($email);
  436.                 $email = htmlentities($email, ENT_NOQUOTES);
  437.                 fwrite($fp_email_txt,$email);
  438.                 fclose($fp_email_txt);
  439.  
  440.                 if (isset($_REQUEST['url']) and !empty($_REQUEST['url']) and (ereg("\.", $_REQUEST['url']))) {
  441.                         $fp_url_txt = fopen("$check/comments/pending/$comment_entry_dir/url.txt","w");
  442.                         $url = str_replace('http://', '', $_REQUEST['url']);
  443.                         $url = strtolower($url);
  444.                         $url = trim($url);
  445.                         $url = 'http://' . $url;
  446.                         $url = htmlentities($url, ENT_NOQUOTES);
  447.                         fwrite($fp_url_txt,$url);
  448.                         fclose($fp_url_txt);
  449.                 }
  450.  
  451.                 if (isset($_REQUEST['cauthor']) and !empty($_REQUEST['cauthor'])) {
  452.                         $fp_cauthor_txt = fopen("$check/comments/pending/$comment_entry_dir/author.txt","w");
  453.                         fwrite($fp_cauthor_txt,$_REQUEST['cauthor']);
  454.                         fclose($fp_cauthor_txt);
  455.                 }
  456.  
  457.                 $key_rand = str_rand(14);
  458.                 $fp_key_txt = fopen("$check/comments/pending/$comment_entry_dir/key.txt","w");
  459.                 fwrite($fp_key_txt,$key_rand);
  460.                 fclose($fp_key_txt);
  461.  
  462.                 $comment_quote = ucfirst($_REQUEST['new_comment']);
  463.                 $comment_quote = htmlentities($comment_quote, ENT_NOQUOTES);
  464.  
  465.                 $sig_author_file = "data/author.txt";
  466.                 $fp_sig_author = fopen($sig_author_file, "r");
  467.                 $sig_author = fread($fp_sig_author, filesize($sig_author_file));
  468.                 fclose($fp_sig_author);
  469.  
  470.                 $sig_url = $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/";
  471.                 $sig_url = str_replace('//', '/', $sig_url);
  472.                 $sig_url = "http://" . $sig_url;
  473.  
  474.                 $email_to = strtolower($_REQUEST['email']);
  475.                 $email_to = $firstname . " " . $lastname . ' <' . $email_to . '>';
  476.  
  477.                 if (file_exists("data/email.txt")) {
  478.                         $from_email_file = "data/email.txt";
  479.                         $fp_from_email = fopen($from_email_file, "r");
  480.                         $from_email = fread($fp_from_email, filesize($from_email_file));
  481.                         fclose($fp_from_email);
  482.                 }
  483.  
  484.                 $mailer = 'MAJ/0.14 (PHP/' . phpversion() . ')';
  485.  
  486.                 $commented_entry_title_file = "data/items/{$_REQUEST['entry']}/title.txt";
  487.                 $fp_commented_entry_title = fopen($commented_entry_title_file, "r");
  488.                 $commented_entry_title = fread($fp_commented_entry_title, filesize($commented_entry_title_file));
  489.                 fclose($fp_commented_entry_title);
  490.  
  491.                 if (!file_exists("data/nak.txt") and file_exists("data/email.txt")) {
  492.                         $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";
  493.  
  494.                         $comment_thanks = wordwrap($comment_thanks);
  495.  
  496.                         mail($email_to, "Thanks for posting a comment on my blog!", $comment_thanks,
  497.                                 "From: $from_email\r\n" .
  498.                                 "Reply-To: $from_email\r\n" .
  499.                                 "X-Mailer: $mailer");
  500.                 }
  501.  
  502.                 if (file_exists("data/email.txt")) {
  503.                         $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.";
  504.  
  505.                         $comment_notice = wordwrap($comment_notice);
  506.  
  507.                         mail($from_email, "Pending Blog Comment", $comment_notice,
  508.                                 "From: $from_email\r\n" .
  509.                                 "Reply-To: $from_email\r\n" .
  510.                                 "X-Mailer: $mailer");
  511.                 }
  512.  
  513.                 if (!file_exists("data/comments")) {
  514.                         mkdir("data/comments");
  515.                 }
  516.  
  517.                 if (!file_exists("data/comments/pending")) {
  518.                         mkdir("data/comments/pending");
  519.                 }
  520.  
  521.                 $pending_comment_flag = $_REQUEST['entry'];
  522.  
  523.                 if (!file_exists("data/comments/pending/$pending_comment_flag")) {
  524.                         mkdir("data/comments/pending/$pending_comment_flag");
  525.                 }
  526.  
  527.                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag/count.txt","r");
  528.                 $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$pending_comment_flag/count.txt"));
  529.                 fclose($fp_comment_count_txt);
  530.                 $comment_count_value = $comment_count_value + 1;
  531.                 $fp_comment_count_txt = fopen("data/comments/pending/$pending_comment_flag/count.txt","w");
  532.                 fwrite($fp_comment_count_txt, $comment_count_value);
  533.                 fclose($fp_comment_count_txt);
  534.  
  535.                 }
  536.  
  537.         }
  538.         else {
  539.                 echo '<title>' . $default_title . '</title>';
  540.                 if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  541.                         $filter = $_REQUEST['archive'] . "*";
  542.                 }
  543.                 else {
  544.                         $filter = "*";
  545.                 }
  546.         }
  547. }
  548. else {
  549.         echo '<title>' . $default_title . '</title>';
  550.         if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  551.                 $filter = $_REQUEST['archive'] . "*";
  552.         }
  553.         else {
  554.                 $filter = "*";
  555.         }
  556. }
  557.  
  558. ?>
  559.  
  560. <?php
  561.  
  562. if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and file_exists("data/items/{$_REQUEST['entry']}")) {
  563.  
  564.         $cat_dir = file_get_contents("data/items/{$_REQUEST['entry']}/category.txt");
  565.  
  566.         if (!file_exists("data/categories/$cat_dir/private.txt")) {
  567.  
  568.                 if (!file_exists("data/items/{$_REQUEST['entry']}/passwd.txt")) {
  569.  
  570.                         if (!file_exists("data/items/{$_REQUEST['entry']}/private.txt")) {
  571.  
  572.                                 $description = file_get_contents("data/items/{$_REQUEST['entry']}/body.txt");
  573.                                 $description = strip_tags($description);
  574.                                 $description = html_entity_decode($description);
  575.                                 $description = str_replace("&","&amp;",$description);
  576.                                 $description = str_replace("<","&lt;",$description);
  577.                                 $description = str_replace(">","&gt;",$description);
  578.                                 $description = str_replace("<br>"," ",$description);
  579.                                 $description = str_replace("<br />"," ",$description);
  580.                                 $description = str_replace("\r"," ",$description);
  581.                                 $description = str_replace("\n"," ",$description);
  582.                                 $description = str_replace(chr(10)," ",$description);
  583.                                 $description = str_replace(chr(13)," ",$description);
  584.                                 $description = trim($description);
  585.                                 $description = substr($description,0,210);
  586.                                 $description = htmlentities($description, ENT_NOQUOTES);
  587.  
  588.                                                 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"))))) {
  589.                                         $badwords = file_get_contents("data/pf-badwords.txt");
  590.                                         if (file_exists("data/pf-censor.txt")) {
  591.                                                 $censor = file_get_contents("data/pf-censor.txt");
  592.                                         }
  593.                                         else {
  594.                                                 $censor = "[expletive]";
  595.                                         }
  596.                                         $description = preg_replace("/\b($badwords)\b/i",$censor,$description);
  597.                                 }
  598.  
  599.                                 echo "<meta name=\"description\" content=\"{$description}\">";
  600.                         }
  601.                 }
  602.         }
  603. }
  604.  
  605. ?>
  606.  
  607. <style>
  608.  
  609. body
  610. {
  611.         color: <?php
  612. if (file_exists("data/colors/font.txt")) {
  613.         $font_color = file_get_contents("data/colors/font.txt");
  614.         echo $font_color;
  615. }
  616. else {
  617.         echo "#666666";
  618. }
  619. ?>;
  620.         margin: 0px 0px 10px 10px;
  621.         padding: 0px;
  622.         text-align: left;
  623.         font-family: verdana, helvetica, sans-serif;
  624.         background-color: <?php
  625. if (file_exists("data/colors/bg.txt")) {
  626.         $background_color = file_get_contents("data/colors/bg.txt");
  627.         echo $background_color;
  628. }
  629. else {
  630.         echo "#FFFFFF";
  631. }
  632. ?>;
  633.         <?php
  634.         if (file_exists("images/background.gif") and !file_exists("images/background.jpg") and !file_exists("images/background.png")) { ?>
  635.         background-image: url('images/background.gif');
  636.         background-attachment: <?php if (file_exists("data/bg-scroll.txt")) { echo scroll; } else { echo fixed; } ?>;
  637.         background-repeat: <?php if (file_exists("data/bg-repeat.txt")) { readfile("data/bg-repeat.txt"); } else { echo repeat; } ?>;
  638.         background-position: <?php if (file_exists("data/bg-position.txt")) { readfile("data/bg-position.txt"); } else { echo "top left"; } ?>;
  639.         <?php
  640.         }
  641.         if (!file_exists("images/background.gif") and file_exists("images/background.jpg") and !file_exists("images/background.png")) { ?>
  642.         background-image: url('images/background.jpg');
  643.         background-attachment: <?php if (file_exists("data/bg-scroll.txt")) { echo scroll; } else { echo fixed; } ?>;
  644.         background-repeat: <?php if (file_exists("data/bg-repeat.txt")) { readfile("data/bg-repeat.txt"); } else { echo repeat; } ?>;
  645.         background-position: <?php if (file_exists("data/bg-position.txt")) { readfile("data/bg-position.txt"); } else { echo "top left"; } ?>;
  646.         <?php
  647.         }
  648.         if (!file_exists("images/background.gif") and !file_exists("images/background.jpg") and file_exists("images/background.png")) { ?>
  649.         background-image: url('images/background.png');
  650.         background-attachment: <?php if (file_exists("data/bg-scroll.txt")) { echo scroll; } else { echo fixed; } ?>;
  651.         background-repeat: <?php if (file_exists("data/bg-repeat.txt")) { readfile("data/bg-repeat.txt"); } else { echo repeat; } ?>;
  652.         background-position: <?php if (file_exists("data/bg-position.txt")) { readfile("data/bg-position.txt"); } else { echo "top left"; } ?>;
  653.         <?php
  654.         }
  655.         ?>
  656. }
  657.  
  658. p, td
  659. {
  660.         font-size: 11px;
  661. }
  662.  
  663. a
  664. {
  665.         font-weight: bold;
  666.         text-decoration: none;
  667. }
  668.  
  669. a:link
  670. {
  671.         color: <?php
  672. if (file_exists("data/colors/link.txt")) {
  673.         $a_link_color = file_get_contents("data/colors/link.txt");
  674.         echo $a_link_color;
  675. }
  676. else {
  677.         echo "#666666";
  678. }
  679. ?>;
  680. }
  681.  
  682. a:visited
  683. {
  684.         color: <?php
  685. if (file_exists("data/colors/vlink.txt")) {
  686.         $a_visited_color = file_get_contents("data/colors/vlink.txt");
  687.         echo $a_visited_color;
  688. }
  689. else {
  690.         echo "#666666";
  691. }
  692. ?>;
  693. }
  694.  
  695. a:hover
  696. {
  697.         color: <?php
  698. if (file_exists("data/colors/hover.txt")) {
  699.         $a_hover_color = file_get_contents("data/colors/hover.txt");
  700.         echo $a_hover_color;
  701. }
  702. else {
  703.         echo "#336699";
  704. }
  705. ?>;
  706. }
  707.  
  708. a:active {
  709.         color: <?php
  710. if (file_exists("data/colors/hover.txt")) {
  711.         $a_active_color = file_get_contents("data/colors/hover.txt");
  712.         echo $a_active_color;
  713. }
  714. else {
  715.         echo "#336699";
  716. }
  717. ?>;
  718. }
  719. #panel_title
  720. {
  721.         font-family: verdana, helvetica, sans-serif;
  722.         font-size: 12px;
  723.         font-weight: bold;
  724.         color: <?php
  725. if (file_exists("data/colors/pt-font.txt")) {
  726.         $panel_title_font_color = file_get_contents("data/colors/pt-font.txt");
  727.         echo $panel_title_font_color;
  728. }
  729. else {
  730.         echo "#666666";
  731. }
  732. ?>;
  733.         padding: 5px 5px 5px 5px;
  734.         background-color: <?php
  735. if (file_exists("data/colors/pt-bg.txt")) {
  736.         $panel_title_background_color = file_get_contents("data/colors/pt-bg.txt");
  737.         echo $panel_title_background_color;
  738. }
  739. else {
  740.         echo "transparent";
  741. }
  742. ?>;
  743.         margin: 10px 0px 0px 0px;
  744.         border-color: <?php
  745. if (file_exists("data/colors/border.txt")) {
  746.         $panel_title_border_color = file_get_contents("data/colors/border.txt");
  747.         echo $panel_title_border_color;
  748. }
  749. else {
  750.         echo "#CCCCCC";
  751. }
  752. ?>;
  753.         border-width: 1px 1px 0px 1px;
  754.         border-style: solid solid none solid;
  755. }
  756. #panel_body
  757. {
  758.         font-family: verdana, helvetica, sans-serif;
  759.         font-size: 11px;
  760.         color: <?php
  761. if (file_exists("data/colors/pb-font.txt")) {
  762.         $panel_body_font_color = file_get_contents("data/colors/pb-font.txt");
  763.         echo $panel_body_font_color;
  764. }
  765. else {
  766.         echo "#666666";
  767. }
  768. ?>;
  769.         padding: 5px 5px 5px 5px;
  770.         background-color: <?php
  771. if (file_exists("data/colors/pb-bg.txt")) {
  772.         $panel_body_background_color = file_get_contents("data/colors/pb-bg.txt");
  773.         echo $panel_body_background_color;
  774. }
  775. else {
  776.         echo "transparent";
  777. }
  778. ?>;
  779.         margin: 0px;
  780.         border-color: <?php
  781. if (file_exists("data/colors/border.txt")) {
  782.         $panel_body_border_color = file_get_contents("data/colors/border.txt");
  783.         echo $panel_body_border_color;
  784. }
  785. else {
  786.         echo "#CCCCCC";
  787. }
  788. ?>;
  789.         border-width: 1px 1px 1px 1px;
  790.         border-style: solid solid solid solid;
  791. }
  792. #panel_footer
  793. {
  794.         font-family: verdana, helvetica, sans-serif;
  795.         font-size: 11px;
  796.         color: <?php
  797. if (file_exists("data/colors/pf-font.txt")) {
  798.         $panel_footer_font_color = file_get_contents("data/colors/pf-font.txt");
  799.         echo $panel_footer_font_color;
  800. }
  801. else {
  802.         echo "#666666";
  803. }
  804. ?>;
  805.         padding: 5px 5px 5px 5px;
  806.         background-color: <?php
  807. if (file_exists("data/colors/pf-bg.txt")) {
  808.         $panel_footer_background_color = file_get_contents("data/colors/pf-bg.txt");
  809.         echo $panel_footer_background_color;
  810. }
  811. else {
  812.         echo "transparent";
  813. }
  814. ?>;
  815.         margin: 0px;
  816.         border-color: <?php
  817. if (file_exists("data/colors/border.txt")) {
  818.         $panel_footer_border_color = file_get_contents("data/colors/border.txt");
  819.         echo $panel_footer_border_color;
  820. }
  821. else {
  822.         echo "#CCCCCC";
  823. }
  824. ?>;
  825.         border-width: 0px 1px 1px 1px;
  826.         border-style: none solid solid solid;
  827.         text-align: right;
  828. }
  829. .input {        
  830.         color: <?php
  831. if (file_exists("data/colors/border.txt")) {
  832.         $input_color = file_get_contents("data/colors/border.txt");
  833.         echo $input_color;
  834. }
  835. else {
  836.         echo "#666666";
  837. }
  838. ?>;
  839.         background: #FFFFFF;
  840.         border: <?php
  841. if (file_exists("data/colors/border.txt")) {
  842.         $panel_footer_border_color = file_get_contents("data/colors/border.txt");
  843.         echo $panel_footer_border_color;
  844. }
  845. else {
  846.         echo "#999999";
  847. }
  848. ?> solid 1px;
  849.         width: 300px;
  850.         font-family: verdana,helvetica,sans-serif;
  851.         font-size: 11px;
  852. }
  853. .search {      
  854.         color: #666666;
  855.         background: #FFFFFF;
  856.         width: 100%;
  857.         font-family: verdana,helvetica,sans-serif;
  858.         font-size: 11px;
  859. }
  860. #panel_free {
  861.         padding: 0px 5px 0px 5px;
  862.         margin: 10px 0px 0px 0px;
  863. }
  864. </style>
  865.  
  866. <link rel="alternate" type="application/rss+xml" title="RSS 0.91" href="rss.php?ver=0.91">
  867. <link rel="alternate" type="application/rss+xml" title="RSS 1.0" href="rss.php?ver=1.0">
  868. <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss.php?ver=2.0">
  869.  
  870. <?php
  871. if (file_exists("header.php")) {
  872.         include("header.php");
  873.         echo '<p></p>';
  874. }
  875. ?>
  876.  
  877. <table border=0 cellspacing=0 cellpadding=0 width=<?php if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) { echo "990"; } else { echo "905"; } ?>>
  878. <tr><td width=175 valign=top>
  879.  
  880. <div id=panel_title>Profile</div>
  881. <div id=panel_body>
  882. <?php
  883. if (file_exists("images/profile.gif")) {
  884.         $profile_gif_image_size = getimagesize("images/profile.gif");
  885.         $profile_gif_image_width = $profile_gif_image_size[0];
  886.         $profile_gif_image_height = $profile_gif_image_size[1];
  887.  
  888.         $max_profile_gif_image_width = 163;
  889.  
  890.         if ($profile_gif_image_width > $max_profile_gif_image_width) {  
  891.                 $sizefactor = (double) ($max_profile_gif_image_width / $profile_gif_image_width) ;
  892.                 $profile_gif_image_width = (int) ($profile_gif_image_width * $sizefactor);
  893.                 $profile_gif_image_height = (int) ($profile_gif_image_height * $sizefactor);
  894.         }
  895.  
  896.         echo "<img src=images/profile.gif border=0 width=";
  897.         echo $profile_gif_image_width;
  898.         echo " height=";
  899.         echo $profile_gif_image_height;
  900.         echo " align=left>";
  901. }
  902. if (file_exists("images/profile.jpg")) {
  903.         $profile_jpg_image_size = getimagesize("images/profile.jpg");
  904.         $profile_jpg_image_width = $profile_jpg_image_size[0];
  905.         $profile_jpg_image_height = $profile_jpg_image_size[1];
  906.  
  907.         $max_profile_jpg_image_width = 163;
  908.  
  909.         if ($profile_jpg_image_width > $max_profile_jpg_image_width) {  
  910.                 $sizefactor = (double) ($max_profile_jpg_image_width / $profile_jpg_image_width) ;
  911.                 $profile_jpg_image_width = (int) ($profile_jpg_image_width * $sizefactor);
  912.                 $profile_jpg_image_height = (int) ($profile_jpg_image_height * $sizefactor);
  913.         }
  914.  
  915.         echo "<img src=images/profile.jpg border=0 width=";
  916.         echo $profile_jpg_image_width;
  917.         echo " height=";
  918.         echo $profile_jpg_image_height;
  919.         echo " align=left>";
  920. }
  921. if (file_exists("images/profile.png")) {
  922.         $profile_png_image_size = getimagesize("images/profile.png");
  923.         $profile_png_image_width = $profile_png_image_size[0];
  924.         $profile_png_image_height = $profile_png_image_size[1];
  925.  
  926.         $max_profile_png_image_width = 163;
  927.  
  928.         if ($profile_png_image_width > $max_profile_png_image_width) {  
  929.                 $sizefactor = (double) ($max_profile_png_image_width / $profile_png_image_width) ;
  930.                 $profile_png_image_width = (int) ($profile_png_image_width * $sizefactor);
  931.                 $profile_png_image_height = (int) ($profile_png_image_height * $sizefactor);
  932.         }
  933.  
  934.         echo "<img src=images/profile.png border=0 width=";
  935.         echo $profile_png_image_width;
  936.         echo " height=";
  937.         echo $profile_png_image_height;
  938.         echo " align=left>";
  939. }
  940. include("data/profile.php");
  941. ?>
  942. </div>
  943.  
  944. <div id=panel_title>Navigation</div>
  945. <div id=panel_body>
  946. <a href="<?php echo $_SERVER['PHP_SELF']; ?>">Home</a><br>
  947.  
  948. <?php
  949.  
  950. if (file_exists("data/bb.txt") and file_exists("data/members/active")) {
  951.         echo '<a href=member.php?id=all>Members</a><br>';
  952. }
  953.  
  954. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  955.         echo '<a href=add.php>Add Entry</a><br>';
  956.         echo '<a href=settings.php>Settings</a><br>';
  957.         echo '<a href=panels.php>Panels</a><br>';
  958.         echo '<a href=cat.php>Categories</a><br>';
  959.         echo '<a href=colors.php>Colors</a><br>';
  960.         echo '<a href=login.php>Logout</a>';
  961. } 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")) {
  962.         if (file_exists("data/members/active/{$_SESSION['logged_in']}/rw.txt")) {
  963.                 echo '<a href=add.php>Add Entry</a><br>';
  964.         }
  965.         echo '<a href=options.php>Options</a><br>';
  966.         echo '<a href=login.php>Logout</a>';
  967. }
  968. else {
  969.         if (file_exists("data/bb.txt") and file_exists("data/reg.txt")) {
  970.                 echo '<a href=reg.php>Register</a><br>';
  971.         }
  972.         echo '<a href=login.php>Login</a>';
  973. }
  974. ?>
  975.  
  976. </div>
  977.  
  978. <?php
  979. if (file_exists("data/sticky")) {
  980.         if ($dh_sticky_list = opendir("data/sticky")) {
  981.                 while (($entry_sticky_list = readdir($dh_sticky_list)) !== false) {
  982.  
  983.                         if (file_exists("data/items/$entry_sticky_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  984.                                 continue;
  985.                         }
  986.  
  987.                         if (file_exists("data/items/$entry_sticky_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  988.                                 continue;
  989.                         }
  990.  
  991.                         $get_cat_dir = file_get_contents("data/items/$entry_sticky_list/category.txt");
  992.  
  993.                         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")) {
  994.                                 continue;
  995.                         }
  996.  
  997.                         if ($entry_sticky_list != "." && $entry_sticky_list != ".." && fnmatch("*", $entry_sticky_list)) {
  998.                                 $show_sticky_list[] = $entry_sticky_list;
  999.                         }
  1000.                 }
  1001.                 closedir($dh_sticky_list);
  1002.         }
  1003.  
  1004.         sort($show_sticky_list);
  1005.         reset($show_sticky_list);
  1006.         $count_sticky_list = count($show_sticky_list);
  1007.        
  1008.         if ($count_sticky_list > 0) {
  1009.                 echo '<div id=panel_title>Quick Links</div>';
  1010.                 echo '<div id=panel_body>';
  1011.                 foreach ($show_sticky_list as $sticky_list_entry) {
  1012.                         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=';
  1013.                         echo $sticky_list_entry;
  1014.                         echo '>';
  1015.                         readfile("data/items/$sticky_list_entry/title.txt");
  1016.                         echo '</a><br>';
  1017.                 }
  1018.                 echo '</div>';
  1019.         }
  1020. }
  1021. ?>
  1022.  
  1023.  
  1024.  
  1025. <?php
  1026. if (file_exists("data/panels")) {
  1027.         if ($dh_panel_list = opendir("data/panels")) {
  1028.                 while (($entry_panel_list = readdir($dh_panel_list)) !== false) {
  1029.  
  1030.                         if (file_exists("data/panels/$entry_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1031.                                 continue;
  1032.                         }
  1033.  
  1034.                         if (file_exists("data/panels/$entry_panel_list/right.txt")) {
  1035.                                 continue;
  1036.                         }
  1037.  
  1038.                         if ($entry_panel_list != "." && $entry_panel_list != ".." && fnmatch("*", $entry_panel_list)) {
  1039.                                 $show_panel_list[] = $entry_panel_list;
  1040.                         }
  1041.                 }
  1042.                 closedir($dh_panel_list);
  1043.         }
  1044.  
  1045.         sort($show_panel_list);
  1046.         reset($show_panel_list);
  1047.         $count_panel_list = count($show_panel_list);
  1048.        
  1049.         if ($count_panel_list > 0) {
  1050.                 foreach ($show_panel_list as $panel_list_entry) {
  1051.                         if (!file_exists("data/panels/$panel_list_entry/free.txt")) {
  1052.                                 echo '<div id=panel_title>';
  1053.                                 readfile("data/panels/$panel_list_entry/title.txt");
  1054.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1055.                                         echo "<a href=panels.php#{$panel_list_entry}>";
  1056.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  1057.                                 }
  1058.                                 echo '</div><div id=panel_body>';
  1059.                         }
  1060.                         if (file_exists("data/panels/$panel_list_entry/free.txt")) {
  1061.                                 echo '<div id=panel_free>';
  1062.                         }
  1063.                         include("data/panels/$panel_list_entry/panel.php");
  1064.                         echo '</div>';
  1065.                 }
  1066.         }
  1067. }
  1068. ?>
  1069.  
  1070. </td><td width=15>&nbsp;</td><td valign=top width=<?php if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) { echo "610"; } else { echo "525"; } ?>>
  1071.  
  1072. <?php
  1073.  
  1074. 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'])) {
  1075.  
  1076. if ($dh_latest_post_items = opendir($dir)) {
  1077.         while (($entry_latest_post_items = readdir($dh_latest_post_items)) !== false) {
  1078.  
  1079.                 if (file_exists("data/items/$entry_latest_post_items/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1080.                         continue;
  1081.                 }
  1082.  
  1083.                 if (file_exists("data/items/$entry_latest_post_items/member.txt") and (!isset($_SESSION['logged_in']))) {
  1084.                         continue;
  1085.                 }
  1086.  
  1087.                 $cat_dir = file_get_contents("data/items/$entry_latest_post_items/category.txt");
  1088.  
  1089.                 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")) {
  1090.                         continue;
  1091.                 }
  1092.  
  1093.                 if ($entry_latest_post_items != "." && $entry_latest_post_items != ".." && fnmatch("*", $entry_latest_post_items)) {
  1094.                         $show_latest_post_items[] = $entry_latest_post_items;
  1095.                 }
  1096.         }
  1097.         closedir($dh_latest_post_items);
  1098. }
  1099.  
  1100. rsort($show_latest_post_items);
  1101. reset($show_latest_post_items);
  1102. $count_latest_post_items = count($show_latest_post_items);
  1103.  
  1104. if ($count_latest_post_items > 0) {
  1105.  
  1106.         echo "<div id=panel_title>Latest Entries</div><div id=panel_body>";
  1107.         echo "<table border=0 cellspacing=1 cellpadding=2 bgcolor=#cccccc width=100%>";
  1108.         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>";
  1109.  
  1110.         $increment_latest_post_entries = 0;
  1111.         $show_latest_post_entries = 5;
  1112.  
  1113.         while ($increment_latest_post_entries <= $show_latest_post_entries) {
  1114.                 echo '<tr><td bgcolor=#ffffff><a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $show_latest_post_items[$increment_latest_post_entries] . '>';
  1115.                 readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/title.txt");
  1116.                 echo '</a></td>';
  1117.                 echo '<td bgcolor=#ffffff><a href=member.php?id=';
  1118.                 readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/author.txt");
  1119.                 echo '>';
  1120.                 readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/author.txt");
  1121.                 echo '</a></td>';
  1122.                 echo '<td bgcolor=#ffffff align=right>';
  1123.                 if (!file_exists("$dir/$show_latest_post_items[$increment_latest_post_entries]/views.txt")) {
  1124.                         echo 0;
  1125.                 }
  1126.                 else {
  1127.                         readfile("$dir/$show_latest_post_items[$increment_latest_post_entries]/views.txt");
  1128.                 }
  1129.                 echo '</td>';
  1130.  
  1131.                 if ($dh_summary_comments = opendir("$dir/$show_latest_post_items[$increment_latest_post_entries]/comments/live")) {
  1132.                         while (($entry_summary_comments = readdir($dh_summary_comments)) !== false) {
  1133.                                 if ($entry_summary_comments != "." && $entry_summary_comments != ".." && fnmatch("*", $entry_summary_comments)) {
  1134.                                         $items_summary_comments[] = $entry_summary_comments;
  1135.                                 }
  1136.                         }
  1137.                 closedir($dh_summary_comments);
  1138.                 }
  1139.                 rsort($items_summary_comments);
  1140.                 $summary_comments = count($items_summary_comments);
  1141.                 if ($summary_comments < 1) {
  1142.                         echo "<td bgcolor=#ffffff align=right><p>0</p></td>";
  1143.                         echo "<td bgcolor=#ffffff align=right><p>";
  1144.                         $iso_year = substr($show_latest_post_items[$increment_latest_post_entries],0,4);
  1145.                         $iso_month = substr($show_latest_post_items[$increment_latest_post_entries],4,2);
  1146.                         $iso_day = substr($show_latest_post_items[$increment_latest_post_entries],6,2);
  1147.                         $iso_last = $iso_year . "-" . $iso_month . "-" . $iso_day;
  1148.                         echo $iso_last;
  1149.                         echo "</p></td>";
  1150.                 }
  1151.                 else {
  1152.                         echo "<td bgcolor=#ffffff align=right><p>$summary_comments</p></td>";
  1153.                         echo "<td bgcolor=#ffffff align=right><p>";
  1154.                         $iso_year = substr($items_summary_comments[0],0,4);
  1155.                         $iso_month = substr($items_summary_comments[0],4,2);
  1156.                         $iso_day = substr($items_summary_comments[0],6,2);
  1157.                         $iso_last = $iso_year . "-" . $iso_month . "-" . $iso_day;
  1158.                         echo $iso_last;
  1159.                         echo "</p></td>";
  1160.                 }
  1161.                 unset($items_summary_comments);
  1162.  
  1163.                 $increment_latest_post_entries = $increment_latest_post_entries + 1;
  1164.         }
  1165. }
  1166.  
  1167. if ($count_latest_post_items > 0) {
  1168.         echo "</table></div>";
  1169. }
  1170.  
  1171. }
  1172.  
  1173. ?>
  1174.  
  1175. <?php
  1176.  
  1177. if (is_dir($dir)) {
  1178.         if ($dh = opendir($dir)) {
  1179.                 while (($entry_main = readdir($dh)) !== false) {
  1180.  
  1181.                         if (file_exists("data/items/$entry_main/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1182.                                 continue;
  1183.                         }
  1184.  
  1185.                         if (file_exists("data/items/$entry_main/member.txt") and (!isset($_SESSION['logged_in']))) {
  1186.                                 continue;
  1187.                         }
  1188.  
  1189.                         $cat_dir = file_get_contents("data/items/$entry_main/category.txt");
  1190.  
  1191.                         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")) {
  1192.                                 continue;
  1193.                         }
  1194.  
  1195.                         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']))) {
  1196.                                 continue;
  1197.                         }
  1198.  
  1199.                         if ($entry_main != "." && $entry_main != ".." && fnmatch($filter, $entry_main)) {
  1200.                                 if (isset($_REQUEST['category']) and !empty($_REQUEST['category']) and file_exists(strip_tags(strtolower(str_replace(" ", "-", "data/categories/{$_REQUEST['category']}"))))) {
  1201.                                         $category = str_replace(" ", "-", $_REQUEST['category']);
  1202.                                         $category = strtolower($category);
  1203.                                         $category = strip_tags($category);
  1204.                                         if (file_exists("data/items/$entry_main/category.txt") and (file_get_contents("data/items/$entry_main/category.txt") == "$category")) {
  1205.                                                 $items[] = $entry_main;
  1206.                                         }
  1207.                                 }
  1208.                                 elseif (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and file_exists("data/members/active/{$_REQUEST['author']}") and file_exists("data/bb.txt")) {
  1209.                                         if (file_exists("data/items/$entry_main/author.txt") and (file_get_contents("data/items/$entry_main/author.txt") == $_REQUEST['author'])) {
  1210.                                                 $items[] = $entry_main;
  1211.                                         }
  1212.                                 }
  1213.                                 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")) {
  1214.                                         if (file_exists("data/items/$entry_main/author.txt") and (file_get_contents("data/items/$entry_main/author.txt") == $_REQUEST['author'])) {
  1215.                                                 $items[] = $entry_main;
  1216.                                         }
  1217.                                 }
  1218.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "private")) {
  1219.                                         if (file_exists("data/items/$entry_main/private.txt")) {
  1220.                                                 $items[] = $entry_main;
  1221.                                         }
  1222.                                 }
  1223.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "member")) {
  1224.                                         if (file_exists("data/items/$entry_main/member.txt")) {
  1225.                                                 $items[] = $entry_main;
  1226.                                         }
  1227.                                 }
  1228.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "passwd")) {
  1229.                                         if (file_exists("data/items/$entry_main/passwd.txt")) {
  1230.                                                 $items[] = $entry_main;
  1231.                                         }
  1232.                                 }
  1233.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "filedrop")) {
  1234.                                         if (file_exists("data/items/$entry_main/filedrop")) {
  1235.                                                 $items[] = $entry_main;
  1236.                                         }
  1237.                                 }
  1238.                                 elseif (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "album")) {
  1239.                                         if (file_exists("images/$entry_main/album")) {
  1240.                                                 $items[] = $entry_main;
  1241.                                         }
  1242.                                 }
  1243.                                 else {
  1244.                                         $items[] = $entry_main;
  1245.                                 }
  1246.                         }
  1247.                 }
  1248.                 closedir($dh);
  1249.         }
  1250. }
  1251.  
  1252. if (!file_exists("data/old.txt")) {
  1253.         rsort($items);
  1254. }
  1255.  
  1256. if (file_exists("data/old.txt")) {
  1257.         sort($items);
  1258. }
  1259.  
  1260. if (isset($_REQUEST['category']) and !empty($_REQUEST['category'])) {
  1261.  
  1262.         $category = str_replace(" ", "-", $_REQUEST['category']);
  1263.         $category = strtolower($category);
  1264.         $category = strip_tags($category);
  1265.  
  1266.         if (file_exists("data/categories/$category/book.txt")) {
  1267.                 sort($items);
  1268.         }
  1269. }
  1270.  
  1271. reset($items);
  1272.  
  1273. $start = $_REQUEST['start'];
  1274.  
  1275. if (!isset($_REQUEST['start']) or empty($_REQUEST['start'])) {
  1276.         $start = 0;
  1277. }
  1278.  
  1279. $end=$start+$increase;
  1280.    
  1281. $disp=array_slice($items,$start,$increase);
  1282.  
  1283. foreach ($disp as $d) {
  1284.  
  1285.         if (file_exists("$dir/$d/category.txt")) {
  1286.                 $category_check = 'data/categories/' . file_get_contents("$dir/$d/category.txt");
  1287.                 if (!file_exists($category_check)) {
  1288.                         unlink("$dir/$d/category.txt");
  1289.                 }
  1290.         }
  1291.  
  1292.         if (file_exists("$dir/$d/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1293.                 continue;
  1294.         }
  1295.  
  1296.         if (file_exists("$dir/$d/member.txt") and (!isset($_SESSION['logged_in']))) {
  1297.                 continue;
  1298.         }
  1299.  
  1300.         echo '<table border=0 cellspacing=0 cellpadding=0 bgcolor=#CCCCCC style="background-color: transparent;"><tr><td width=';
  1301.         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  1302.                 echo "610";
  1303.         }
  1304.         else {
  1305.                 echo "525";
  1306.         }
  1307.         echo '><div id=panel_title>';
  1308.         readfile("$dir/$d/title.txt");
  1309.        
  1310.         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1311.                 echo '<a href=del.php?entry=';
  1312.                 echo $d;
  1313.                 echo '><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete entry"></a>';
  1314.                 echo '<a href=edit.php?entry=';
  1315.                 echo $d;
  1316.                 echo '><img src=images/widget.edit.png border=0 width=11 height=11 align=right alt="edit entry"></a>';
  1317.                 if (file_exists("$dir/$d/passwd.txt")) {
  1318.                         echo '<img src=images/widget.protected.png border=0 width=11 height=11 align=right alt="protected entry">';
  1319.                 }
  1320.  
  1321.                 if (file_exists("$dir/$d/private.txt")) {
  1322.                         echo '<img src=images/widget.private.png border=0 width=11 height=11 align=right alt="private entry">';
  1323.                 }
  1324.                 if (file_exists("$dir/$d/member.txt")) {
  1325.                         echo '<img src=images/widget.member.png border=0 width=11 height=11 align=right alt="member-only entry">';
  1326.                 }
  1327.                 if (file_exists("$dir/$d/cat.txt")) {
  1328.                         echo '<img src=images/widget.cat.png border=0 width=11 height=11 align=right alt="always display">';
  1329.                 }
  1330.                 if (file_exists("$dir/$d/category.txt")) {
  1331.  
  1332.                         $read_cat_dir = file_get_contents("$dir/$d/category.txt");
  1333.  
  1334.                         if (file_exists("data/categories/$read_cat_dir/private.txt")) {
  1335.                                 echo '<img src=images/widget.hidden.png border=0 width=11 height=11 align=right alt="category hidden">';
  1336.                         }
  1337.  
  1338.                         if (file_exists("data/nocat.txt")) {
  1339.                                 echo '<img src=images/widget.isolated.png border=0 width=11 height=11 align=right alt="category isolated">';
  1340.                         }
  1341.  
  1342.                         if (file_exists("data/categories/$read_cat_dir/book.txt")) {
  1343.                                 echo '<img src=images/widget.booked.png border=0 width=11 height=11 align=right alt="category booked">';
  1344.                         }
  1345.  
  1346.                         echo '<img src=images/widget.filed.png border=0 width=11 height=11 align=right alt="filed under ';
  1347.                         readfile("$dir/$d/category.txt");
  1348.                         echo '">';
  1349.                 }
  1350.  
  1351.         }
  1352.  
  1353.         echo '</div><div id=panel_body><table border=0 cellspacing=0 cellpadding=0><tr>';
  1354.  
  1355.         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt") and file_exists("$dir/$d/author.txt")) {
  1356.                 echo "<td width=85 valign=top><p>";
  1357.                 $author = file_get_contents("$dir/$d/author.txt");
  1358.                 echo "<a href=member.php?id=$author>";
  1359.                 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"))) {
  1360.                         if (file_exists("images/avatar.gif")) {
  1361.                                 $avatar_gif_image_size = getimagesize("images/avatar.gif");
  1362.                                 $avatar_gif_image_width = $avatar_gif_image_size[0];
  1363.                                 $avatar_gif_image_height = $avatar_gif_image_size[1];
  1364.  
  1365.                                 $max_avatar_gif_image_width = 80;
  1366.                        
  1367.                                 if ($avatar_gif_image_width > $max_avatar_gif_image_width) {  
  1368.                                         $sizefactor = (double) ($max_avatar_gif_image_width / $avatar_gif_image_width) ;
  1369.                                         $avatar_gif_image_width = (int) ($avatar_gif_image_width * $sizefactor);
  1370.                                         $avatar_gif_image_height = (int) ($avatar_gif_image_height * $sizefactor);
  1371.                                 }
  1372.  
  1373.                                 echo "<img src=images/avatar.gif border=0 width=";
  1374.                                 echo $avatar_gif_image_width;
  1375.                                 echo " height=";
  1376.                                 echo $avatar_gif_image_height;
  1377.                         }
  1378.                         if (file_exists("images/avatar.jpg")) {
  1379.                                 $avatar_jpg_image_size = getimagesize("images/avatar.jpg");
  1380.                                 $avatar_jpg_image_width = $avatar_jpg_image_size[0];
  1381.                                 $avatar_jpg_image_height = $avatar_jpg_image_size[1];
  1382.                        
  1383.                                 $max_avatar_jpg_image_width = 80;
  1384.                        
  1385.                                 if ($avatar_jpg_image_width > $max_avatar_jpg_image_width) {  
  1386.                                         $sizefactor = (double) ($max_avatar_jpg_image_width / $avatar_jpg_image_width) ;
  1387.                                         $avatar_jpg_image_width = (int) ($avatar_jpg_image_width * $sizefactor);
  1388.                                         $avatar_jpg_image_height = (int) ($avatar_jpg_image_height * $sizefactor);
  1389.                                 }
  1390.  
  1391.                                 echo "<img src=images/avatar.jpg border=0 width=";
  1392.                                 echo $avatar_jpg_image_width;
  1393.                                 echo " height=";
  1394.                                 echo $avatar_jpg_image_height;
  1395.                         }
  1396.                         if (file_exists("images/avatar.png")) {
  1397.                                 $avatar_png_image_size = getimagesize("images/avatar.png");
  1398.                                 $avatar_png_image_width = $avatar_png_image_size[0];
  1399.                                 $avatar_png_image_height = $avatar_png_image_size[1];
  1400.                        
  1401.                                 $max_avatar_png_image_width = 80;
  1402.                        
  1403.                                 if ($avatar_png_image_width > $max_avatar_png_image_width) {  
  1404.                                         $sizefactor = (double) ($max_avatar_png_image_width / $avatar_png_image_width) ;
  1405.                                         $avatar_png_image_width = (int) ($avatar_png_image_width * $sizefactor);
  1406.                                         $avatar_png_image_height = (int) ($avatar_png_image_height * $sizefactor);
  1407.                                 }
  1408.                        
  1409.                                 echo "<img src=images/avatar.png border=0 width=";
  1410.                                 echo $avatar_png_image_width;
  1411.                                 echo " height=";
  1412.                                 echo $avatar_png_image_height;
  1413.                         }
  1414.                 echo "><br>";
  1415.                 }
  1416.                 elseif (file_exists("images/members/$author/avatar.jpg") or file_exists("images/members/$author/avatar.gif") or file_exists("images/members/$author/avatar.png")) {
  1417.                         if (file_exists("images/members/$author/avatar.gif")) {
  1418.                                 $avatar_gif_image_size = getimagesize("images/members/$author/avatar.gif");
  1419.                                 $avatar_gif_image_width = $avatar_gif_image_size[0];
  1420.                                 $avatar_gif_image_height = $avatar_gif_image_size[1];
  1421.  
  1422.                                 $max_avatar_gif_image_width = 80;
  1423.                        
  1424.                                 if ($avatar_gif_image_width > $max_avatar_gif_image_width) {  
  1425.                                         $sizefactor = (double) ($max_avatar_gif_image_width / $avatar_gif_image_width) ;
  1426.                                         $avatar_gif_image_width = (int) ($avatar_gif_image_width * $sizefactor);
  1427.                                         $avatar_gif_image_height = (int) ($avatar_gif_image_height * $sizefactor);
  1428.                                 }
  1429.  
  1430.                                 echo "<img src=images/members/$author/avatar.gif border=0 width=";
  1431.                                 echo $avatar_gif_image_width;
  1432.                                 echo " height=";
  1433.                                 echo $avatar_gif_image_height;
  1434.                         }
  1435.                         if (file_exists("images/members/$author/avatar.jpg")) {
  1436.                                 $avatar_jpg_image_size = getimagesize("images/members/$author/avatar.jpg");
  1437.                                 $avatar_jpg_image_width = $avatar_jpg_image_size[0];
  1438.                                 $avatar_jpg_image_height = $avatar_jpg_image_size[1];
  1439.                        
  1440.                                 $max_avatar_jpg_image_width = 80;
  1441.                        
  1442.                                 if ($avatar_jpg_image_width > $max_avatar_jpg_image_width) {  
  1443.                                         $sizefactor = (double) ($max_avatar_jpg_image_width / $avatar_jpg_image_width) ;
  1444.                                         $avatar_jpg_image_width = (int) ($avatar_jpg_image_width * $sizefactor);
  1445.                                         $avatar_jpg_image_height = (int) ($avatar_jpg_image_height * $sizefactor);
  1446.                                 }
  1447.  
  1448.                                 echo "<img src=images/members/$author/avatar.jpg border=0 width=";
  1449.                                 echo $avatar_jpg_image_width;
  1450.                                 echo " height=";
  1451.                                 echo $avatar_jpg_image_height;
  1452.                         }
  1453.                         if (file_exists("images/members/$author/avatar.png")) {
  1454.                                 $avatar_png_image_size = getimagesize("images/members/$author/avatar.png");
  1455.                                 $avatar_png_image_width = $avatar_png_image_size[0];
  1456.                                 $avatar_png_image_height = $avatar_png_image_size[1];
  1457.                        
  1458.                                 $max_avatar_png_image_width = 80;
  1459.                        
  1460.                                 if ($avatar_png_image_width > $max_avatar_png_image_width) {  
  1461.                                         $sizefactor = (double) ($max_avatar_png_image_width / $avatar_png_image_width) ;
  1462.                                         $avatar_png_image_width = (int) ($avatar_png_image_width * $sizefactor);
  1463.                                         $avatar_png_image_height = (int) ($avatar_png_image_height * $sizefactor);
  1464.                                 }
  1465.                        
  1466.                                 echo "<img src=images/members/$author/avatar.png border=0 width=";
  1467.                                 echo $avatar_png_image_width;
  1468.                                 echo " height=";
  1469.                                 echo $avatar_png_image_height;
  1470.                         }
  1471.                 echo "><br>";
  1472.                 }
  1473.                 echo "$author</a><br>";
  1474.                 if ((file_get_contents("data/username.txt") == $author) and file_exists("data/rank.txt")) {
  1475.                         echo "administrator<br>";
  1476.                 }
  1477.                 elseif (file_exists("data/members/active/$author/rank.txt") and file_exists("data/rank.txt")) {
  1478.                         $rank = file_get_contents("data/members/active/$author/rank.txt");
  1479.                         echo "$rank<br>";
  1480.                 }
  1481.                 elseif (!file_exists("data/members/active/$author/rank.txt") and file_exists("data/rank.txt")) {
  1482.                         echo "member<br>";
  1483.                 }
  1484.  
  1485.                 if ($dh_posts = opendir("data/items")) {
  1486.                         while (($entry_posts = readdir($dh_posts)) !== false) {
  1487.  
  1488.                                 if (file_exists("data/items/$entry_posts/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1489.                                         continue;
  1490.                                 }
  1491.  
  1492.                                 if (file_exists("data/items/$entry_posts/member.txt") and (!isset($_SESSION['logged_in']))) {
  1493.                                         continue;
  1494.                                 }
  1495.  
  1496.                                 $post_cat_dir = file_get_contents("data/items/$entry_posts/category.txt");
  1497.  
  1498.                                 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")) {
  1499.                                         continue;
  1500.                                 }
  1501.  
  1502.                                 if ($entry_posts != "." && $entry_posts != ".." && fnmatch("*", $entry_posts)) {
  1503.                                         if (file_exists("data/members/active/$author") and file_exists("data/bb.txt")) {
  1504.                                                 if (file_exists("data/items/$entry_posts/author.txt") and (file_get_contents("data/items/$entry_posts/author.txt") == $author)) {
  1505.                                                         $items_posts[] = $entry_posts;
  1506.                                                 }
  1507.                                         }
  1508.                                         elseif (!file_exists("data/members/active/$author") and (file_get_contents("data/username.txt") == $author) and file_exists("data/bb.txt")) {
  1509.                                                 if (file_exists("data/items/$entry_posts/author.txt") and (file_get_contents("data/items/$entry_posts/author.txt") == $author)) {
  1510.                                                         $items_posts[] = $entry_posts;
  1511.                                                 }
  1512.                                         }
  1513.                                 }
  1514.                         }
  1515.                 closedir($dh_posts);
  1516.                 }
  1517.                 $posts = count($items_posts);
  1518.                 if ($posts == 1) {
  1519.                         echo "$posts post";
  1520.                 }
  1521.                 if ($posts > 1) {
  1522.                         echo "$posts posts";
  1523.                 }
  1524.                 unset($items_posts);
  1525.  
  1526.                 echo "</p></td><td width=513 valign=top>";
  1527.  
  1528.         }
  1529.         else {
  1530.                 echo "<td width=598 valign=top>";
  1531.         }
  1532.  
  1533.         if (file_exists("$dir/$d/passwd.txt")) {
  1534.                 $passwd = file_get_contents("$dir/$d/passwd.txt");
  1535.         }
  1536.  
  1537.         if (isset($_REQUEST['passwd']) and !empty($_REQUEST['passwd'])) {
  1538.                 $crypt_passwd = sha1($_REQUEST['passwd']);
  1539.                 $crypt_passwd = md5($crypt_passwd);
  1540.                 $crypt_passwd = crypt($crypt_passwd, $crypt_passwd);
  1541.         }
  1542.  
  1543.         echo '<font style="font-size: 10px; color: #999999;">';
  1544.         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"))))) {
  1545.                 $xavatar_author = file_get_contents("$dir/$d/author.txt");
  1546.                 echo "<a href=member.php?id=$xavatar_author>$xavatar_author</a> - ";
  1547.         }
  1548.         readfile("$dir/$d/date.txt");
  1549.         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1550.                 if (file_exists("$dir/$d/revisions.txt")) {
  1551.                         echo ' (Revision ';
  1552.                         readfile("$dir/$d/revisions.txt");
  1553.                         echo ')';
  1554.                 }
  1555.                 if (file_exists("$dir/$d/category.txt")) {
  1556.                         echo ' Filed under ';
  1557.                         $category_key = file_get_contents("$dir/$d/category.txt");
  1558.                         $category_key = strtolower($category_key);
  1559.                         if (file_exists("data/categories/{$category_key}/title.txt")) {
  1560.                                 $category_dsp = file_get_contents("data/categories/{$category_key}/title.txt");
  1561.                                 echo "$category_key ($category_dsp)";
  1562.                         }
  1563.                         else {
  1564.                                 echo "$category_key";
  1565.                         }
  1566.                 }
  1567.         }
  1568.         echo '</font><font style="font-size: 5px;"><br><br></font>';
  1569.  
  1570.         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))) {
  1571.                 echo "This entry is password protected. If you know the magic word, click <a href=passwd.php?entry=$d>here</a> to enter it.";
  1572.         }
  1573.         else {
  1574.                 $entry_body = file_get_contents("$dir/$d/body.txt");
  1575.                 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"))))) {
  1576.                         $badwords = file_get_contents("data/pf-badwords.txt");
  1577.                         if (file_exists("data/pf-censor.txt")) {
  1578.                                 $censor = file_get_contents("data/pf-censor.txt");
  1579.                         }
  1580.                         else {
  1581.                                 $censor = "[expletive]";
  1582.                         }
  1583.                         $entry_body = preg_replace("/\b($badwords)\b/i",$censor,$entry_body);
  1584.                 }
  1585.                 echo $entry_body;
  1586.         }
  1587.  
  1588.  
  1589.         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")) {
  1590.                 $sig = file_get_contents("data/sig.txt");
  1591.                 echo "<br><br>--<br>$sig";
  1592.         }
  1593.         elseif (file_exists("data/members/active/$author/sig.txt") and file_exists("data/bb.txt")  and file_exists("data/bb-sig.txt")) {
  1594.                 $sig = file_get_contents("data/members/active/$author/sig.txt");
  1595.                 echo "<br><br>--<br>$sig";
  1596.         }
  1597.  
  1598.         echo '</td></tr></table></div><div id=panel_footer>';
  1599.         echo '<font style="font-size: 10px; color: ';
  1600.         if (file_exists("data/colors/pf-font.txt")) {
  1601.                 readfile("data/colors/pf-font.txt");
  1602.         }
  1603.         else {
  1604.                 echo "#999999";
  1605.         }
  1606.         echo ';">';
  1607.  
  1608. if (!file_exists("data/nocomment.txt")) {
  1609.  
  1610.         if (!file_exists("$dir/$d/comments/live")) {
  1611.                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=comments>add comment</a>';
  1612.         }
  1613.         else {
  1614.                 if ($dh_comments = opendir("$dir/$d/comments/live")) {
  1615.                         while (($entry_comments = readdir($dh_comments)) !== false) {
  1616.                                 if ($entry_comments != "." && $entry_comments != ".." && fnmatch("*", $entry_comments)) {
  1617.                                         $items_comments[] = $entry_comments;
  1618.                                 }
  1619.                         }
  1620.                 closedir($dh_comments);
  1621.                 }
  1622.                 $comments = count($items_comments);
  1623.                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=comments>';
  1624.                 if ($comments == 1) {
  1625.                         echo $comments . ' comment';
  1626.                 }
  1627.                 elseif ($comments < 1) {
  1628.                         echo 'add comment';
  1629.                 }
  1630.                 else {
  1631.                         echo $comments . ' comments';
  1632.                 }
  1633.                 echo '</a>';
  1634.                 unset($items_comments);
  1635.         }
  1636.  
  1637. }
  1638. else {
  1639.         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '>permalink</a>';
  1640. }
  1641.  
  1642.         if (file_exists("$dir/$d/views.txt")) {
  1643.                 $fp_views_txt = fopen("$dir/$d/views.txt","r");
  1644.                 $views_value = fread($fp_views_txt,filesize("$dir/$d/views.txt"));
  1645.                 fclose($fp_views_txt);
  1646.                 if ($views_value == 1) {
  1647.                         echo ' ( ' . $views_value . ' view ) ';
  1648.                 }
  1649.                 elseif ($views_value > 1) {
  1650.                         echo ' ( ' . $views_value . ' views ) ';
  1651.                 }
  1652.                 else {
  1653.                         echo ' ';
  1654.                 }
  1655.         }
  1656.  
  1657.         if (!file_exists("images/$d/album")) {
  1658.                 echo ' ';
  1659.         }
  1660.         else {
  1661.                 if ($dh_album = opendir("images/$d/album")) {
  1662.                         while (($entry_album = readdir($dh_album)) !== false) {
  1663.                                 if ($entry_album != "." && $entry_album != ".." && fnmatch("*", $entry_album)) {
  1664.                                         $items_album[] = $entry_album;
  1665.                                 }
  1666.                         }
  1667.                 closedir($dh_album);
  1668.                 }
  1669.                 $album = count($items_album);
  1670.                 echo ' | <a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=album>';
  1671.                 if ($album == 1) {
  1672.                         echo $album . ' image';
  1673.                 }
  1674.                 elseif ($album < 1) {
  1675.                         echo 'album';
  1676.                 }
  1677.                 else {
  1678.                         echo $album . ' images';
  1679.                 }
  1680.                 echo '</a>';
  1681.                 unset($items_album);
  1682.         }
  1683.  
  1684.         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)) {
  1685.                 if (!file_exists("$dir/$d/album")) {
  1686.                         mkdir("$dir/$d/album");
  1687.                 }
  1688.                 if ((!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1689.                         $fp_album_views_txt = fopen("$dir/$d/album/views.txt","r");
  1690.                         $album_views_value = fread($fp_album_views_txt,filesize("$dir/$d/album/views.txt"));
  1691.                         fclose($fp_album_views_txt);
  1692.                         $album_views_value = $album_views_value + 1;
  1693.                         $fp_album_views_txt = fopen("$dir/$d/album/views.txt","w");
  1694.                         fwrite($fp_album_views_txt, $album_views_value);
  1695.                         fclose($fp_album_views_txt);
  1696.                 }
  1697.         }
  1698.  
  1699.         $fp_album_views_txt = fopen("$dir/$d/album/views.txt","r");
  1700.         $album_views_value = fread($fp_album_views_txt,filesize("$dir/$d/album/views.txt"));
  1701.         fclose($fp_album_views_txt);
  1702.         if ($album_views_value == 1) {
  1703.                 echo ' ( ' . $album_views_value . ' view ) ';
  1704.         }
  1705.         elseif ($album_views_value > 1) {
  1706.                 echo ' ( ' . $album_views_value . ' views ) ';
  1707.         }
  1708.         else {
  1709.                 echo ' ';
  1710.         }
  1711.  
  1712.         if (!file_exists("data/items/$d/filedrop/files")) {
  1713.                 echo ' ';
  1714.         }
  1715.         else {
  1716.                 if ($dh_filedrop = opendir("data/items/$d/filedrop/files")) {
  1717.                         while (($dl_file = readdir($dh_filedrop)) !== false) {
  1718.                                 if ($dl_file != "." && $dl_file != ".." && fnmatch("*", $dl_file)) {
  1719.                                         $items_filedrop[] = $dl_file;
  1720.                                 }
  1721.                         }
  1722.                 closedir($dh_filedrop);
  1723.                 }
  1724.                 $filedrop = count($items_filedrop);
  1725.                 echo ' | <a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&show=filedrop>';
  1726.                 if ($filedrop == 1) {
  1727.                         echo $filedrop . ' file';
  1728.                 }
  1729.                 elseif ($filedrop < 1) {
  1730.                         echo 'filedrop';
  1731.                 }
  1732.                 else {
  1733.                         echo $filedrop . ' files';
  1734.                 }
  1735.                 echo '</a> ';
  1736.                 unset($items_filedrop);
  1737.         }
  1738.  
  1739.         if (isset($_REQUEST['entry']) and !empty($_REQUEST['entry']) and isset($_REQUEST['show']) and !empty($_REQUEST['show']) and ($_REQUEST['show'] == filedrop)) {
  1740.                 if (!file_exists("$dir/$d/filedrop")) {
  1741.                         mkdir("$dir/$d/filedrop");
  1742.                 }
  1743.                 if (file_exists("data/items/$d/filedrop/files") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  1744.                         $fp_filedrop_views_txt = fopen("$dir/$d/filedrop/views.txt","r");
  1745.                         $filedrop_views_value = fread($fp_filedrop_views_txt,filesize("$dir/$d/filedrop/views.txt"));
  1746.                         fclose($fp_filedrop_views_txt);
  1747.                         $filedrop_views_value = $filedrop_views_value + 1;
  1748.                         $fp_filedrop_views_txt = fopen("$dir/$d/filedrop/views.txt","w");
  1749.                         fwrite($fp_filedrop_views_txt, $filedrop_views_value);
  1750.                         fclose($fp_filedrop_views_txt);
  1751.                 }
  1752.         }
  1753.  
  1754.         $fp_filedrop_views_txt = fopen("$dir/$d/filedrop/views.txt","r");
  1755.         $filedrop_views_value = fread($fp_filedrop_views_txt,filesize("$dir/$d/filedrop/views.txt"));
  1756.         fclose($fp_filedrop_views_txt);
  1757.         if ($filedrop_views_value == 1) {
  1758.                 echo ' ( ' . $filedrop_views_value . ' view ) ';
  1759.         }
  1760.         elseif ($filedrop_views_value > 1) {
  1761.                 echo ' ( ' . $filedrop_views_value . ' views ) ';
  1762.         }
  1763.         else {
  1764.                 echo ' ';
  1765.         }
  1766.  
  1767.         if (!file_exists("data/nopdf.txt") and file_exists("$dir/$d/pdf/file")) {
  1768.  
  1769.                 echo "| <a href={$_SERVER['PHP_SELF']}?entry=$d&show=pdf>pdf</a> ";
  1770.  
  1771.                 if (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username)) {
  1772.                         $pdf_views_value = file_get_contents("$dir/$d/pdf/count/views.txt");
  1773.                         $pdf_views_value = $pdf_views_value + 1;
  1774.                         $fp_pdf_views_txt = fopen("$dir/$d/pdf/count/views.txt","w");
  1775.                         fwrite($fp_pdf_views_txt, $pdf_views_value);
  1776.                         fclose($fp_pdf_views_txt);
  1777.                 }
  1778.  
  1779.                 $pdf_views_value = file_get_contents("$dir/$d/pdf/count/views.txt");
  1780.                 if ($pdf_views_value == 1) {
  1781.                         echo ' ( ' . $pdf_views_value . ' view ) ';
  1782.                 }
  1783.                 elseif ($pdf_views_value > 1) {
  1784.                         echo ' ( ' . $pdf_views_value . ' views ) ';
  1785.                 }
  1786.                 else {
  1787.                         echo ' ';
  1788.                 }
  1789.         }
  1790.  
  1791.         if (!file_exists("data/nocomment.txt")) {
  1792.                 echo '| <a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '>permalink</a></font>';
  1793.         }
  1794.  
  1795.         echo '</div></td></tr></table>';
  1796.  
  1797.         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")) {
  1798.                 echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  1799.  
  1800.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  1801.                         echo "610";
  1802.                 }
  1803.                 else {
  1804.                         echo "525";
  1805.                 }
  1806.  
  1807.                 echo '><tr><td>';
  1808.                 echo '<div id=panel_title>Album';
  1809.                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1810.                         echo '<a href=del.php?entry=';
  1811.                         echo $d;
  1812.                         echo '&target=album><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete album"></a>';
  1813.                 }
  1814.                 echo '</div><div id=panel_body>';
  1815.  
  1816.                 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))) {
  1817.                         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.";
  1818.                 }
  1819.                 else {
  1820.        
  1821.                         /* thumbnail auto-clean-up (20060409) - This should delete thumbnails of non-existent album images. */
  1822.        
  1823.                         if (file_exists("images/$d/thumbnails")) {
  1824.                                 if ($dh_album = opendir("images/$d/thumbnails")) {
  1825.                                         while (($thumbnail_album = readdir($dh_album)) !== false) {
  1826.                                                 if ($thumbnail_album != "." && $thumbnail_album != ".." && fnmatch("*", $thumbnail_album)) {
  1827.                                                         $current_thumbnail = "images/$d/thumbnails/$thumbnail_album";
  1828.                                                         $parent_image = str_replace("-thumbnail.jpg","",$thumbnail_album);
  1829.                                                         $parent_image = "images/$d/album/$parent_image";
  1830.                                                         if (file_exists($current_thumbnail) and !file_exists($parent_image)) {
  1831.                                                                 unlink($current_thumbnail);
  1832.                                                         }
  1833.                                                 }
  1834.                                         }
  1835.                                 }
  1836.                         }
  1837.        
  1838.                         /* 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. */
  1839.        
  1840.                         if (file_exists("images/$d/album")) {
  1841.                                 if ($dh_album = opendir("images/$d/album")) {
  1842.                                         while (($entry_album = readdir($dh_album)) !== false) {
  1843.                                                 if ($entry_album != "." && $entry_album != ".." && fnmatch("*", $entry_album)) {
  1844.                                                         $sort_album[] = $entry_album;
  1845.                                                 }
  1846.                                         }
  1847.                                 closedir($dh_album);
  1848.                                 }
  1849.        
  1850.                                 sort($sort_album);
  1851.                                 reset($sort_album);
  1852.                                 $count_album_entry = count($sort_album);
  1853.                                
  1854.                                 if ($count_album_entry < 1) {
  1855.                                         rmdirr("images/$d/album");
  1856.                                         rmdirr("images/$d/thumbnails");                        
  1857.                                 }
  1858.                                 else {
  1859.                                         foreach($sort_album as $album_entry) {
  1860.                                                 $current_image = "images/$d/album/$album_entry";
  1861.                                                 $current_image_size = getimagesize($current_image);
  1862.                                                 $current_width = $current_image_size[0];
  1863.                                                 $current_height = $current_image_size[1];
  1864.                                                 $max_width = 98;
  1865.                                                 $max_height = 73;
  1866.        
  1867.                                                 if (($current_width > $max_width) || ($current_height > $max_height)) {  
  1868.                                                         if ($current_height > $current_width) {
  1869.                                                                 $sizefactor = (double) ($max_height / $current_height);
  1870.                                                         }
  1871.                                                         else {
  1872.                                                                 $sizefactor = (double) ($max_width / $current_width) ;
  1873.                                                         }
  1874.                                                 }
  1875.        
  1876.                                                 $new_width = (int) ($current_width * $sizefactor);
  1877.                                                 $new_height = (int) ($current_height * $sizefactor);
  1878.        
  1879.                                                 /* 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. */
  1880.        
  1881.                                                 if (!file_exists("images/$d/thumbnails/{$album_entry}-thumbnail.jpg")) {
  1882.        
  1883.                                                         $work_thumb = imagecreatetruecolor($new_width,$new_height);
  1884.                                                         $get_mimetype = image_type_to_mime_type(exif_imagetype($current_image));
  1885.                                                         switch($get_mimetype) {
  1886.                                                                 case "image/jpg":
  1887.                                                                 case "image/jpeg":
  1888.                                                                         $work_image = imagecreatefromjpeg($current_image);
  1889.                                                                         break;
  1890.                                                                 case "image/gif":
  1891.                                                                         $work_image = imagecreatefromgif($current_image);
  1892.                                                                         break;
  1893.                                                                 case "image/png":
  1894.                                                                         $work_image = imagecreatefrompng($current_image);
  1895.                                                                         break;
  1896.                                                         }
  1897.        
  1898.                                                         imagecopyresampled($work_thumb, $work_image ,0, 0, 0, 0, $new_width, $new_height, $current_width, $current_height);
  1899.        
  1900.                                                         if (!file_exists("images/$d/thumbnails")) {
  1901.                                                                 mkdir("images/$d/thumbnails");
  1902.                                                         }
  1903.        
  1904.                                                         imagejpeg($work_thumb, "images/$d/thumbnails/{$album_entry}-thumbnail.jpg", 80);
  1905.        
  1906.                                                 }
  1907. //                                              echo "<a href=\"images/$d/album/$album_entry\">";
  1908.                                                 echo "<a href=\"album.php?entry=$d&show=$album_entry\">";
  1909.  
  1910.                                                 /* auto-thumbnails (20060519) - Just in case php-gd does not exist, do it the old way. */
  1911.  
  1912.                                                 if (!file_exists("images/$d/thumbnails/{$album_entry}-thumbnail.jpg")) {
  1913.                                                         echo "<img src=\"images/$d/album/$album_entry\" width=$new_width height=$new_height border=0 hspace=2 vspace=2";
  1914.                                                 }
  1915.                                                 else {
  1916.                                                         echo "<img src=\"images/$d/thumbnails/{$album_entry}-thumbnail.jpg\" width=$new_width height=$new_height border=0 hspace=2 vspace=2";
  1917.                                                 }
  1918.  
  1919.                                                 if (file_exists("data/items/$d/album/captions/{$album_entry}.txt")) {
  1920.                                                         echo ' alt="';
  1921.                                                         readfile("data/items/$d/album/captions/{$album_entry}.txt");
  1922.                                                         echo '"';
  1923.                                                 }
  1924.                                                 echo "></a>";
  1925.                                         }
  1926.                                 }
  1927.                         }
  1928.                 }
  1929.                 echo '</div></td></tr></table>';
  1930.  
  1931.         }
  1932.  
  1933.         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")) {
  1934.                 echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  1935.  
  1936.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  1937.                         echo "610";
  1938.                 }
  1939.                 else {
  1940.                         echo "525";
  1941.                 }
  1942.  
  1943.                 echo '><tr><td>';
  1944.                 echo '<div id=panel_title>Filedrop';
  1945.                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  1946.                         echo '<a href=del.php?entry=';
  1947.                         echo $d;
  1948.                         echo '&target=filedrop><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete filedrop"></a>';
  1949.                 }
  1950.                 echo '</div><div id=panel_body>';
  1951.  
  1952.                 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))) {
  1953.                         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.";
  1954.                 }
  1955.                 else {
  1956.  
  1957.                         if ($dh_filedrop = opendir("data/items/$d/filedrop/files")) {
  1958.                                 while (($dl_file = readdir($dh_filedrop)) !== false) {
  1959.                                         if ($dl_file != "." && $dl_file != ".." && fnmatch("*", $dl_file)) {
  1960.                                                 echo '<table border=0 cellspacing=0 cellpadding=4><tr><td>';
  1961.                                                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&download=' . $dl_file. '&type=filedrop>';
  1962.                                                 echo '<img src=images/filedrop.png width=36 height=36 border=0 alt="download file"></a></td>';
  1963.                                                 echo '<td><p><b>';
  1964.                                                 echo $dl_file;
  1965.                                                 echo'</b>';
  1966.                                                 if (file_exists("data/items/$d/filedrop/sha1.txt")) {
  1967.                                                         $sha1 = sha1_file("data/items/$d/filedrop/files/$dl_file");
  1968.                                                         echo "<br />$sha1 (<a href=http://www.faqs.org/rfcs/rfc3174 target=_maj>sha1</a>)";
  1969.                                                 }
  1970.                                                 if (file_exists("data/items/$d/filedrop/md5.txt")) {
  1971.                                                         $md5 = md5_file("data/items/$d/filedrop/files/$dl_file");
  1972.                                                         echo "<br />$md5 (<a href=http://www.faqs.org/rfcs/rfc1321 target=_maj>md5</a>)";
  1973.                                                 }
  1974.                                                 $size = filesize("data/items/$d/filedrop/files/$dl_file");
  1975.                                                 $size_string = ($size > 512)?(  ($size/1024 > 512)  ?sprintf("%.02f MB",($size/1024)/1024)  :sprintf("%.02f KB",$size/1024))  :sprintf("%d B",$size);
  1976.                                                 echo "<br />$size_string";
  1977.                                                 $filedrop_count_file = "data/items/$d/filedrop/count/$dl_file" . '.txt';
  1978.                                                 if (file_exists($filedrop_count_file)) {
  1979.                                                         $fp_filedrop_count = fopen($filedrop_count_file, "r");
  1980.                                                         $filedrop_count = fread($fp_filedrop_count, filesize($filedrop_count_file));
  1981.                                                         fclose($fp_filedrop_count);
  1982.                                                         echo '<br>';
  1983.                                                         echo $filedrop_count;
  1984.                                                         if ($filedrop_count == 1) {
  1985.                                                                 echo ' download';
  1986.                                                         }
  1987.                                                         if ($filedrop_count > 1) {
  1988.                                                                 echo ' downloads';
  1989.                                                         }
  1990.                                                 }
  1991.                                                 echo '</p></td></tr></table>';
  1992.                                         }
  1993.                                 }
  1994.                         closedir($dh_filedrop);
  1995.                         }
  1996.                 }
  1997.                 echo '</div></td></tr></table>';
  1998.         }
  1999.  
  2000.         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")) {
  2001.                 echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  2002.  
  2003.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2004.                         echo "610";
  2005.                 }
  2006.                 else {
  2007.                         echo "525";
  2008.                 }
  2009.  
  2010.                 echo '><tr><td>';
  2011.                 echo '<div id=panel_title>PDF';
  2012.                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2013.                         echo '<a href=del.php?entry=';
  2014.                         echo $d;
  2015.                         echo '&target=pdf><img src=images/widget.del.png border=0 width=11 height=11 align=right alt="delete pdf"></a>';
  2016.                 }
  2017.                 echo '</div><div id=panel_body>';
  2018.  
  2019.                 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))) {
  2020.                         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.";
  2021.                 }
  2022.                 else {
  2023.  
  2024.                         if ($dh_pdf = opendir("data/items/$d/pdf/file")) {
  2025.                                 while (($dl_file = readdir($dh_pdf)) !== false) {
  2026.                                         if ($dl_file != "." && $dl_file != ".." && fnmatch("*", $dl_file)) {
  2027.                                                 echo '<table border=0 cellspacing=0 cellpadding=4><tr><td>';
  2028.                                                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $d . '&download=' . $dl_file. '&type=pdf>';
  2029.                                                 echo '<img src=images/pdf.png width=48 height=48 border=0 alt="download file"></a></td>';
  2030.                                                 echo '<td><p><b>';
  2031.                                                 echo $dl_file;
  2032.                                                 echo'</b><br>';
  2033.                                                 $size = filesize("data/items/$d/pdf/file/$dl_file");
  2034.                                                 $size_string = ($size > 512)?(  ($size/1024 > 512)  ?sprintf("%.02f MB",($size/1024)/1024)  :sprintf("%.02f KB",$size/1024))  :sprintf("%d B",$size);
  2035.                                                 echo $size_string;
  2036.                                                 $pdf_count_file = "data/items/$d/pdf/count/dl.txt";
  2037.                                                 if (file_exists($pdf_count_file)) {
  2038.                                                         $fp_pdf_count = fopen($pdf_count_file, "r");
  2039.                                                         $pdf_count = fread($fp_pdf_count, filesize($pdf_count_file));
  2040.                                                         fclose($fp_pdf_count);
  2041.                                                         echo '<br>';
  2042.                                                         echo $pdf_count;
  2043.                                                         if ($pdf_count == 1) {
  2044.                                                                 echo ' download';
  2045.                                                         }
  2046.                                                         if ($pdf_count > 1) {
  2047.                                                                 echo ' downloads';
  2048.                                                         }
  2049.                                                 }
  2050.                                                 echo '</p></td></tr></table>';
  2051.                                         }
  2052.                                 }
  2053.                         closedir($dh_pdf);
  2054.                         }
  2055.                 }
  2056.                 echo '</div></td></tr></table>';
  2057.         }
  2058.  
  2059.         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")) {
  2060.  
  2061.                 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))) {
  2062.                 }
  2063.                 else {
  2064.                         echo '<table border=0 cellspacing=0 cellpadding=0 width=';
  2065.  
  2066.                         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2067.                                 echo "610";
  2068.                         }
  2069.                         else {
  2070.                                 echo "525";
  2071.                         }
  2072.  
  2073.                         echo '><tr><td>';
  2074.                         if ($dh_comments = opendir("$dir/$d/comments/live")) {
  2075.                                 while (($entry_comments = readdir($dh_comments)) !== false) {
  2076.                                         if ($entry_comments != "." && $entry_comments != ".." && fnmatch("*", $entry_comments)) {                                       $show_comments[] = $entry_comments;
  2077.                                         }
  2078.                                 }
  2079.                         closedir($dh_comments);
  2080.                         }
  2081.        
  2082.                         asort($show_comments);
  2083.                         reset($show_comments);
  2084.                         foreach ($show_comments as $comment) {
  2085.                                 echo '<div id=panel_title>';
  2086.        
  2087.                                 if (file_exists("$dir/$d/comments/live/$comment/url.txt")) {
  2088.                                         echo '<a target=_maj href=';
  2089.                                         readfile("$dir/$d/comments/live/$comment/url.txt");
  2090.                                         echo '>';
  2091.                                 }
  2092.        
  2093.                                 readfile("$dir/$d/comments/live/$comment/firstname.txt");
  2094.                                 echo ' ';
  2095.                                 readfile("$dir/$d/comments/live/$comment/lastname.txt");
  2096.        
  2097.                                 if (file_exists("$dir/$d/comments/live/$comment/url.txt")) {
  2098.                                         echo '</a>';
  2099.                                 }
  2100.        
  2101.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2102.                                         echo '  &lt;';
  2103.                                         readfile("$dir/$d/comments/live/$comment/email.txt");
  2104.                                         echo '&gt;';
  2105.                                 }
  2106.        
  2107.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2108.                                         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>';
  2109.                                         echo '<a href=edit.php?entry=' . $d . '&comment=' . $comment . '><img src=images/widget.edit.png width=11 height=11 border=0 align=right alt="edit comment"></a>';
  2110.                                 }
  2111.                                 echo '</div><div id=panel_body><table border=0 cellspacing=0 cellpadding=0><tr>';
  2112.                                
  2113.                                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt") and file_exists("$dir/$d/comments/live/$comment/author.txt")) {
  2114.                                         echo "<td width=85 valign=top><p>";
  2115.                                         $c_author = file_get_contents("$dir/$d/comments/live/$comment/author.txt");
  2116.                                         echo "<a href=member.php?id=$c_author>";
  2117.                                         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"))) {
  2118.                                                 if (file_exists("images/avatar.gif")) {
  2119.                                                         $c_avatar_gif_image_size = getimagesize("images/avatar.gif");
  2120.                                                         $c_avatar_gif_image_width = $c_avatar_gif_image_size[0];
  2121.                                                         $c_avatar_gif_image_height = $c_avatar_gif_image_size[1];
  2122.                        
  2123.                                                         $c_max_avatar_gif_image_width = 80;
  2124.                                                
  2125.                                                         if ($c_avatar_gif_image_width > $c_max_avatar_gif_image_width) {  
  2126.                                                                 $sizefactor = (double) ($c_max_avatar_gif_image_width / $c_avatar_gif_image_width) ;
  2127.                                                                 $c_avatar_gif_image_width = (int) ($c_avatar_gif_image_width * $sizefactor);
  2128.                                                                 $c_avatar_gif_image_height = (int) ($c_avatar_gif_image_height * $sizefactor);
  2129.                                                         }
  2130.                        
  2131.                                                         echo "<img src=images/avatar.gif border=0 width=";
  2132.                                                         echo $c_avatar_gif_image_width;
  2133.                                                         echo " height=";
  2134.                                                         echo $c_avatar_gif_image_height;
  2135.                                                 }
  2136.                                                 if (file_exists("images/avatar.jpg")) {
  2137.                                                         $c_avatar_jpg_image_size = getimagesize("images/avatar.jpg");
  2138.                                                         $c_avatar_jpg_image_width = $c_avatar_jpg_image_size[0];
  2139.                                                         $c_avatar_jpg_image_height = $c_avatar_jpg_image_size[1];
  2140.                                                
  2141.                                                         $c_max_avatar_jpg_image_width = 80;
  2142.                                                
  2143.                                                         if ($c_avatar_jpg_image_width > $c_max_avatar_jpg_image_width) {  
  2144.                                                                 $sizefactor = (double) ($c_max_avatar_jpg_image_width / $c_avatar_jpg_image_width) ;
  2145.                                                                 $c_avatar_jpg_image_width = (int) ($c_avatar_jpg_image_width * $sizefactor);
  2146.                                                                 $c_avatar_jpg_image_height = (int) ($c_avatar_jpg_image_height * $sizefactor);
  2147.                                                         }
  2148.                        
  2149.                                                         echo "<img src=images/avatar.jpg border=0 width=";
  2150.                                                         echo $c_avatar_jpg_image_width;
  2151.                                                         echo " height=";
  2152.                                                         echo $c_avatar_jpg_image_height;
  2153.                                                 }
  2154.                                                 if (file_exists("images/avatar.png")) {
  2155.                                                         $c_avatar_png_image_size = getimagesize("images/avatar.png");
  2156.                                                         $c_avatar_png_image_width = $c_avatar_png_image_size[0];
  2157.                                                         $c_avatar_png_image_height = $c_avatar_png_image_size[1];
  2158.                                                
  2159.                                                         $c_max_avatar_png_image_width = 80;
  2160.                                                
  2161.                                                         if ($c_avatar_png_image_width > $c_max_avatar_png_image_width) {  
  2162.                                                                 $sizefactor = (double) ($c_max_avatar_png_image_width / $c_avatar_png_image_width) ;
  2163.                                                                 $c_avatar_png_image_width = (int) ($c_avatar_png_image_width * $sizefactor);
  2164.                                                                 $c_avatar_png_image_height = (int) ($c_avatar_png_image_height * $sizefactor);
  2165.                                                         }
  2166.                                                
  2167.                                                         echo "<img src=images/avatar.png border=0 width=";
  2168.                                                         echo $c_avatar_png_image_width;
  2169.                                                         echo " height=";
  2170.                                                         echo $c_avatar_png_image_height;
  2171.                                                 }
  2172.                                         echo "><br>";
  2173.                                         }
  2174.                                         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")) {
  2175.                                                 if (file_exists("images/members/$c_author/avatar.gif")) {
  2176.                                                         $c_avatar_gif_image_size = getimagesize("images/members/$c_author/avatar.gif");
  2177.                                                         $c_avatar_gif_image_width = $c_avatar_gif_image_size[0];
  2178.                                                         $c_avatar_gif_image_height = $c_avatar_gif_image_size[1];
  2179.                        
  2180.                                                         $c_max_avatar_gif_image_width = 80;
  2181.                                                
  2182.                                                         if ($c_avatar_gif_image_width > $c_max_avatar_gif_image_width) {  
  2183.                                                                 $sizefactor = (double) ($c_max_avatar_gif_image_width / $c_avatar_gif_image_width) ;
  2184.                                                                 $c_avatar_gif_image_width = (int) ($c_avatar_gif_image_width * $sizefactor);
  2185.                                                                 $c_avatar_gif_image_height = (int) ($c_avatar_gif_image_height * $sizefactor);
  2186.                                                         }
  2187.                        
  2188.                                                         echo "<img src=images/members/$c_author/avatar.gif border=0 width=";
  2189.                                                         echo $c_avatar_gif_image_width;
  2190.                                                         echo " height=";
  2191.                                                         echo $c_avatar_gif_image_height;
  2192.                                                 }
  2193.                                                 if (file_exists("images/members/$c_author/avatar.jpg")) {
  2194.                                                         $c_avatar_jpg_image_size = getimagesize("images/members/$c_author/avatar.jpg");
  2195.                                                         $c_avatar_jpg_image_width = $c_avatar_jpg_image_size[0];
  2196.                                                         $c_avatar_jpg_image_height = $c_avatar_jpg_image_size[1];
  2197.                                                
  2198.                                                         $c_max_avatar_jpg_image_width = 80;
  2199.                                                
  2200.                                                         if ($c_avatar_jpg_image_width > $c_max_avatar_jpg_image_width) {  
  2201.                                                                 $sizefactor = (double) ($c_max_avatar_jpg_image_width / $c_avatar_jpg_image_width) ;
  2202.                                                                 $c_avatar_jpg_image_width = (int) ($c_avatar_jpg_image_width * $sizefactor);
  2203.                                                                 $c_avatar_jpg_image_height = (int) ($c_avatar_jpg_image_height * $sizefactor);
  2204.                                                         }
  2205.                        
  2206.                                                         echo "<img src=images/members/$c_author/avatar.jpg border=0 width=";
  2207.                                                         echo $c_avatar_jpg_image_width;
  2208.                                                         echo " height=";
  2209.                                                         echo $c_avatar_jpg_image_height;
  2210.                                                 }
  2211.                                                 if (file_exists("images/members/$c_author/avatar.png")) {
  2212.                                                         $c_avatar_png_image_size = getimagesize("images/members/$c_author/avatar.png");
  2213.                                                         $c_avatar_png_image_width = $c_avatar_png_image_size[0];
  2214.                                                         $c_avatar_png_image_height = $c_avatar_png_image_size[1];
  2215.                                                
  2216.                                                         $c_max_avatar_png_image_width = 80;
  2217.                                                
  2218.                                                         if ($c_avatar_png_image_width > $c_max_avatar_png_image_width) {  
  2219.                                                                 $sizefactor = (double) ($c_max_avatar_png_image_width / $c_avatar_png_image_width) ;
  2220.                                                                 $c_avatar_png_image_width = (int) ($c_avatar_png_image_width * $sizefactor);
  2221.                                                                 $c_avatar_png_image_height = (int) ($c_avatar_png_image_height * $sizefactor);
  2222.                                                         }
  2223.                                                
  2224.                                                         echo "<img src=images/members/$c_author/avatar.png border=0 width=";
  2225.                                                         echo $c_avatar_png_image_width;
  2226.                                                         echo " height=";
  2227.                                                         echo $c_avatar_png_image_height;
  2228.                                                 }
  2229.                                         echo "><br>";
  2230.                                         }
  2231.                                         echo "$c_author</a><br>";
  2232.                                         if ((file_get_contents("data/username.txt") == $c_author) and file_exists("data/rank.txt")) {
  2233.                                                 echo "administrator<br>";
  2234.                                         }
  2235.                                         elseif (file_exists("data/members/active/$c_author/rank.txt") and file_exists("data/rank.txt")) {
  2236.                                                 $c_rank = file_get_contents("data/members/active/$c_author/rank.txt");
  2237.                                                 echo "$c_rank<br>";
  2238.                                         }
  2239.                                         elseif (!file_exists("data/members/active/$c_author/rank.txt") and file_exists("data/rank.txt")) {
  2240.                                                 echo "member<br>";
  2241.                                         }
  2242.                        
  2243.                                         if ($c_dh_posts = opendir("data/items")) {
  2244.                                                 while (($c_entry_posts = readdir($c_dh_posts)) !== false) {
  2245.                        
  2246.                                                         if (file_exists("data/items/$c_entry_posts/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2247.                                                                 continue;
  2248.                                                         }
  2249.                        
  2250.                                                         if (file_exists("data/items/$c_entry_posts/member.txt") and (!isset($_SESSION['logged_in']))) {
  2251.                                                                 continue;
  2252.                                                         }
  2253.                        
  2254.                                                         $c_post_cat_dir = file_get_contents("data/items/$c_entry_posts/category.txt");
  2255.                        
  2256.                                                         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")) {
  2257.                                                                 continue;
  2258.                                                         }
  2259.                        
  2260.                                                         if ($c_entry_posts != "." && $c_entry_posts != ".." && fnmatch("*", $c_entry_posts)) {
  2261.                                                                 if (file_exists("data/members/active/$c_author") and file_exists("data/bb.txt")) {
  2262.                                                                         if (file_exists("data/items/$c_entry_posts/author.txt") and (file_get_contents("data/items/$c_entry_posts/author.txt") == $c_author)) {
  2263.                                                                                 $c_items_posts[] = $c_entry_posts;
  2264.                                                                         }
  2265.                                                                 }
  2266.                                                                 elseif (!file_exists("data/members/active/$c_author") and (file_get_contents("data/username.txt") == $c_author) and file_exists("data/bb.txt")) {
  2267.                                                                         if (file_exists("data/items/$c_entry_posts/author.txt") and (file_get_contents("data/items/$c_entry_posts/author.txt") == $c_author)) {
  2268.                                                                                 $c_items_posts[] = $c_entry_posts;
  2269.                                                                         }
  2270.                                                                 }
  2271.                                                         }
  2272.                                                 }
  2273.                                         closedir($c_dh_posts);
  2274.                                         }
  2275.                                         $c_posts = count($c_items_posts);
  2276.                                         if ($c_posts == 1) {
  2277.                                                 echo "$c_posts post";
  2278.                                         }
  2279.                                         if ($c_posts > 1) {
  2280.                                                 echo "$c_posts posts";
  2281.                                         }
  2282.                                         unset($c_items_posts);
  2283.                        
  2284.                                         echo "</p></td><td width=513 valign=top>";
  2285.                                 }
  2286.                                 else {
  2287.                                         echo "<td width=598 valign=top>";
  2288.                                 }
  2289.  
  2290.                                 echo '<p><font style="font-size: 10px; color: #999999;">';
  2291.                                 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"))))) {
  2292.                                         $cxavatar_author = file_get_contents("$dir/$d/comments/live/$comment/author.txt");
  2293.                                         echo "<a href=member.php?id=$cxavatar_author>$cxavatar_author</a> - ";
  2294.                                 }
  2295.                                 readfile("$dir/$d/comments/live/$comment/timestamp.txt");
  2296.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2297.                                         if (file_exists("$dir/$d/comments/live/$comment/revisions.txt")) {
  2298.                                                 echo '  (Revision ';
  2299.                                                 readfile("$dir/$d/comments/live/$comment/revisions.txt");
  2300.                                                 echo ')';
  2301.                                         }
  2302.                                 }
  2303.                                 echo '</font><font style="font-size: 5px;"><br><br></font>';
  2304.                                 $entry_comment = file_get_contents("$dir/$d/comments/live/$comment/comment.txt");
  2305.                                 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"))))) {
  2306.                                         $badwords = file_get_contents("data/pf-badwords.txt");
  2307.                                         if (file_exists("data/pf-censor.txt")) {
  2308.                                                 $censor = file_get_contents("data/pf-censor.txt");
  2309.                                         }
  2310.                                         else {
  2311.                                                 $censor = "[expletive]";
  2312.                                         }
  2313.                                         $entry_comment = preg_replace("/\b($badwords)\b/i",$censor,$entry_comment);
  2314.                                 }
  2315.                                 echo $entry_comment;
  2316.                                 echo '</p></tr></table></div>';
  2317.                         }
  2318.                         unset($show_comments);
  2319.                         echo '</td></tr></table>';
  2320.                 }
  2321.  
  2322. if (!file_exists("data/nocomment.txt")) {
  2323.  
  2324.                 echo '<p><table border=0 cellspacing=0 cellpadding=0 width=';
  2325.  
  2326.                 if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2327.                         echo "610";
  2328.                 }
  2329.                 else {
  2330.                         echo "525";
  2331.                 }
  2332.  
  2333.                 echo '><tr><td>';
  2334.                 echo '<p><font style="font-size: 12px;"><b>Add Comment</b></font></p>';
  2335.  
  2336.                 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))) {
  2337.                         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>";
  2338.                 }
  2339.                 else {
  2340.        
  2341.                         $captcha_rand = str_rand(7);
  2342.        
  2343.                         echo "<p>Fill out the form below";
  2344.  
  2345.                         if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")))) {
  2346.                                 echo " and enter <b>$captcha_rand</b> in the anti-spam field";
  2347.                         }
  2348.  
  2349.                         echo " to add your comment.";
  2350.  
  2351.                         if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] != file_get_contents("data/username.txt")))) {
  2352.                                 echo " Note that it will not be posted immediately, but will be ";
  2353.                        
  2354.                                 if (file_exists("data/email.txt")) {
  2355.                                         echo "e-mailed";
  2356.                                 }
  2357.                                 else {
  2358.                                         echo "sent";
  2359.                                 }
  2360.        
  2361.                                 echo " to me first.";
  2362.  
  2363.                                 if (!isset($_SESSION['logged_in']) or (isset($_SESSION['logged_in']) and !file_exists("data/members/active/{$_SESSION['logged_in']}"))) {
  2364.                                         echo " Comments with bogus contact information will be discarded.";
  2365.                                 }
  2366.                         }
  2367.                         echo "</p>";
  2368.  
  2369.                         ?>
  2370.                        
  2371.                         <table border=0 cellspacing=2 cellpadding=0 width=500>
  2372.                         <form enctype="multipart/form-data" action="<?php echo $_SERVER['PHP_SELF']; ?>?entry=<?php echo $d; ?>&show=comments" method="post">
  2373.                         <input type=hidden name=captcha_get value="<?php echo $captcha_rand; ?>">
  2374.                         <tr>
  2375.  
  2376. <?php
  2377. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  2378. ?>
  2379.         <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>
  2380. <?php
  2381. }
  2382. 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")) {
  2383. ?>
  2384.         <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>
  2385. <?php
  2386. }
  2387. else {
  2388.  
  2389. ?>
  2390.  
  2391. <td width=75><p>First Name*</p></td><td width=300><input class=input type=text autocomplete=off name=firstname maxlength=30></td>
  2392.  
  2393. <?php
  2394.  
  2395. }
  2396.  
  2397. ?>
  2398.                         <td rowspan=7 valign=top width=75 align=right>
  2399.                         <table border=0 cellspacing=1 cellpadding=2>
  2400.                         <tr><td><img src=images/smileys/crying.png border=0></td><td><p>:((</p></td><td ><p>crying</p></td></tr>
  2401.                         <tr><td><img src=images/smileys/frown.png border=0></td><td><p>:(</p></td><td><p>frown</p></td></tr>
  2402.                         <tr><td><img src=images/smileys/indifferent.png border=0></td><td><p>:|</p></td><td><p>indifferent</p></td></tr>
  2403.                         <tr><td><img src=images/smileys/laughing.png border=0></td><td><p>:D</p></td><td><p>laughing</p></td></tr>
  2404.                         <tr><td><img src=images/smileys/lick.png border=0></td><td><p>:P</p></td><td><p>lick</p></td></tr>
  2405.                         <tr><td><img src=images/smileys/ohno.png border=0></td><td><p>:O</p></td><td><p>oh no!</p></td></tr>
  2406.                         <tr><td><img src=images/smileys/smile.png border=0></td><td><p>:)</p></td><td><p>smile</p></td></tr>
  2407.                         <tr><td><img src=images/smileys/surprised.png border=0></td><td><p>=)</p></td><td><p>surprised</p></td></tr>
  2408.                         <tr><td><img src=images/smileys/undecided.png border=0></td><td><p>:\</p></td><td><p>undecided</p></td></tr>
  2409.                         <tr><td><img src=images/smileys/wink.png border=0></td><td><p>;)</p></td><td><p>wink</p></td></tr>
  2410.                         </td></tr>
  2411.                         </table>
  2412.  
  2413. <?php
  2414. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  2415. ?>
  2416.         <td width=75><p></p></td><td><input type=hidden name=lastname value="<?php echo trim(str_replace(",","",$logged_in_author[1])); ?>"></p></td>
  2417. <?php
  2418. }
  2419. 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")) {
  2420. ?>
  2421.         <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>
  2422. <?php
  2423. }
  2424. else {
  2425.  
  2426. ?>
  2427.  
  2428.                         <tr><td><p>Last Name*</p></td><td><input class=input type=text autocomplete=off name=lastname maxlength=30></td></tr>
  2429.  
  2430. <?php
  2431.  
  2432. }
  2433.  
  2434. ?>
  2435.  
  2436. <?php
  2437. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  2438.         if (file_exists("data/email.txt")) {
  2439. ?>
  2440.                 <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>
  2441. <?php
  2442.         }
  2443.         else {
  2444.                 echo "<tr><td><p>E-mail*</p></td><td colspan=2><input class=input type=text autocomplete=off name=email maxlength=60></td></tr>";
  2445.         }
  2446. }
  2447. 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")) {
  2448. ?>
  2449.         <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>
  2450. <?php
  2451. }
  2452. else {
  2453.  
  2454. ?>
  2455.  
  2456.                         <tr><td><p>E-mail*</p></td><td colspan=2><input class=input type=text autocomplete=off name=email maxlength=60></td></tr>
  2457.  
  2458. <?php
  2459.  
  2460. }
  2461.  
  2462. ?>
  2463.  
  2464. <?php
  2465. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  2466. ?>
  2467.         <td width=75><p></p></td><td colspan=2><input type=hidden name=url value="<?php file_get_contents("data/url.txt"); ?>"></p></td>
  2468. <?php
  2469. }
  2470. 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")) {
  2471. ?>
  2472.         <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>
  2473. <?php
  2474. }
  2475. else {
  2476.  
  2477. ?>
  2478.  
  2479.                         <tr><td><p>Website</p></td><td colspan=2><input class=input type=text autocomplete=off name=url maxlength=300></td></tr>
  2480.  
  2481. <?php
  2482.  
  2483. }
  2484.  
  2485. ?>
  2486.  
  2487.                         <tr><td><p>Comment*</p></td><td><textarea class=input name=new_comment rows=15></textarea></td></tr>
  2488.                         <?php
  2489.                         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == file_get_contents("data/username.txt"))) {
  2490.                                 echo "<input type=hidden name=captcha_put value=\"$captcha_rand\">";
  2491.                         }
  2492.                         else {
  2493.                                 echo "<tr><td><p>Anti-Spam*</p></td><td><input class=input type=text autocomplete=off name=captcha_put maxlength=7></td></tr>";
  2494.                         }
  2495.                         ?>
  2496.  
  2497.                         <tr><td><p></p></td><td><input class=input type=submit value="click here to submit your comment"></td></tr>
  2498.                         </form>
  2499.                         </table>
  2500.                 <?php } ?>
  2501.                 </td></tr></table></p>
  2502.  
  2503. <?php
  2504. }
  2505.  
  2506. 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']}")))) {
  2507.         if (isset($_REQUEST['show']) and !empty($_REQUEST['show']) and isset($_REQUEST['captcha_put']) and !empty($_REQUEST['captcha_get']) and isset($_REQUEST['firstname']) and !empty($_REQUEST['firstname']) and isset($_REQUEST['lastname']) and !empty($_REQUEST['lastname']) and isset($_REQUEST['email']) and !empty($_REQUEST['email']) and isset($_REQUEST['new_comment']) and !empty($_REQUEST['new_comment']) and isset($_REQUEST['captcha_put']) and !empty($_REQUEST['captcha_put']) and ($_REQUEST['captcha_get'] == $_REQUEST['captcha_put']) and (ereg("@", $_REQUEST['email'])) and (ereg("\.", $_REQUEST['email']))) {
  2508.                 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>';
  2509.         }
  2510. }
  2511.  ?>
  2512.        
  2513.  
  2514.  
  2515.                 <?php
  2516.         }
  2517. }
  2518. ?>
  2519.  
  2520. <?php
  2521. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username) and isset($_REQUEST['entry']) and !empty($_REQUEST['entry'])) {
  2522.         if ($dh_pending_comments = opendir("$dir/$d/comments/pending")) {
  2523.                 while (($entry_pending_comments = readdir($dh_pending_comments)) !== false) {
  2524.                         if ($entry_pending_comments != "." && $entry_pending_comments != ".." && fnmatch("*", $entry_pending_comments)) {
  2525.                                 $show_pending_comments[] = $entry_pending_comments;
  2526.                         }
  2527.                 }
  2528.                 closedir($dh_pending_comments);
  2529.         }
  2530.  
  2531.         asort($show_pending_comments);
  2532.         reset($show_pending_comments);
  2533.         $count_pending_comments = count($show_pending_comments);
  2534.  
  2535.         if ($count_pending_comments > 0) {
  2536.                 if ($count_pending_comments == 1) {
  2537.                         echo '<p><b>Pending Comment</b></p>';
  2538.                 }
  2539.                 else {
  2540.                         echo '<p><b>Pending Comments</b></p>';
  2541.                 }
  2542.                 foreach ($show_pending_comments as $pending_comment) {
  2543.                         echo '<p><table border=0 cellspacing=0 cellpadding=0 width=';
  2544.        
  2545.                         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt")) {
  2546.                                 echo "610";
  2547.                         }
  2548.                         else {
  2549.                                 echo "525";
  2550.                         }
  2551.  
  2552.                         echo '><tr><td>';
  2553.                         echo '<div id=panel_title>';
  2554.  
  2555.                         if (file_exists("$dir/$d/comments/pending/$pending_comment/url.txt")) {
  2556.                                 echo '<a target=_maj href=';
  2557.                                 readfile("$dir/$d/comments/pending/$pending_comment/url.txt");
  2558.                                 echo '>';
  2559.                         }
  2560.        
  2561.                         readfile("$dir/$d/comments/pending/$pending_comment/firstname.txt");
  2562.                         echo ' ';
  2563.                         readfile("$dir/$d/comments/pending/$pending_comment/lastname.txt");
  2564.        
  2565.                         if (file_exists("$dir/$d/comments/pending/$pending_comment/url.txt")) {
  2566.                                 echo '</a>';
  2567.                         }
  2568.        
  2569.                         echo ' &lt;';
  2570.                         readfile("$dir/$d/comments/pending/$pending_comment/email.txt");
  2571.                         echo '&gt;';
  2572.                         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>';
  2573.  
  2574.                         $pending_comment_key_file = "$dir/$d/comments/pending/$pending_comment/key.txt";
  2575.                         $open_pending_comment_key_file = fopen($pending_comment_key_file,"r");
  2576.                         $pending_comment_login_key = fread($open_pending_comment_key_file,filesize($pending_comment_key_file));
  2577.                         fclose($open_pending_comment_key_file);
  2578.  
  2579.                         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>';
  2580.                         echo '</div>';
  2581.                         echo '</div><div id=panel_body><table border=0 cellspacing=0 cellpadding=0><tr>';
  2582.  
  2583.                         if (file_exists("data/bb.txt") and file_exists("data/avatar.txt") and file_exists("$dir/$d/comments/pending/$pending_comment/author.txt")) {
  2584.                                 echo "<td width=85 valign=top><p>";
  2585.                                 $pc_author = file_get_contents("$dir/$d/comments/pending/$pending_comment/author.txt");
  2586.                                 echo "<a href=member.php?id=$pc_author>";
  2587.                                 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"))) {
  2588.                                         if (file_exists("images/avatar.gif")) {
  2589.                                                 $pc_avatar_gif_image_size = getimagesize("images/avatar.gif");
  2590.                                                 $pc_avatar_gif_image_width = $pc_avatar_gif_image_size[0];
  2591.                                                 $pc_avatar_gif_image_height = $pc_avatar_gif_image_size[1];
  2592.                
  2593.                                                 $pc_max_avatar_gif_image_width = 80;
  2594.                                        
  2595.                                                 if ($pc_avatar_gif_image_width > $pc_max_avatar_gif_image_width) {  
  2596.                                                         $sizefactor = (double) ($pc_max_avatar_gif_image_width / $pc_avatar_gif_image_width) ;
  2597.                                                         $pc_avatar_gif_image_width = (int) ($pc_avatar_gif_image_width * $sizefactor);
  2598.                                                         $pc_avatar_gif_image_height = (int) ($pc_avatar_gif_image_height * $sizefactor);
  2599.                                                 }
  2600.                
  2601.                                                 echo "<img src=images/avatar.gif border=0 width=";
  2602.                                                 echo $pc_avatar_gif_image_width;
  2603.                                                 echo " height=";
  2604.                                                 echo $pc_avatar_gif_image_height;
  2605.                                         }
  2606.                                         if (file_exists("images/avatar.jpg")) {
  2607.                                                 $pc_avatar_jpg_image_size = getimagesize("images/avatar.jpg");
  2608.                                                 $pc_avatar_jpg_image_width = $pc_avatar_jpg_image_size[0];
  2609.                                                 $pc_avatar_jpg_image_height = $pc_avatar_jpg_image_size[1];
  2610.                                        
  2611.                                                 $pc_max_avatar_jpg_image_width = 80;
  2612.                                        
  2613.                                                 if ($pc_avatar_jpg_image_width > $pc_max_avatar_jpg_image_width) {  
  2614.                                                         $sizefactor = (double) ($pc_max_avatar_jpg_image_width / $pc_avatar_jpg_image_width) ;
  2615.                                                         $pc_avatar_jpg_image_width = (int) ($pc_avatar_jpg_image_width * $sizefactor);
  2616.                                                         $pc_avatar_jpg_image_height = (int) ($pc_avatar_jpg_image_height * $sizefactor);
  2617.                                                 }
  2618.                
  2619.                                                 echo "<img src=images/avatar.jpg border=0 width=";
  2620.                                                 echo $pc_avatar_jpg_image_width;
  2621.                                                 echo " height=";
  2622.                                                 echo $pc_avatar_jpg_image_height;
  2623.                                         }
  2624.                                         if (file_exists("images/avatar.png")) {
  2625.                                                 $pc_avatar_png_image_size = getimagesize("images/avatar.png");
  2626.                                                 $pc_avatar_png_image_width = $pc_avatar_png_image_size[0];
  2627.                                                 $pc_avatar_png_image_height = $pc_avatar_png_image_size[1];
  2628.                                        
  2629.                                                 $pc_max_avatar_png_image_width = 80;
  2630.                                        
  2631.                                                 if ($pc_avatar_png_image_width > $pc_max_avatar_png_image_width) {  
  2632.                                                         $sizefactor = (double) ($pc_max_avatar_png_image_width / $pc_avatar_png_image_width) ;
  2633.                                                         $pc_avatar_png_image_width = (int) ($pc_avatar_png_image_width * $sizefactor);
  2634.                                                         $pc_avatar_png_image_height = (int) ($pc_avatar_png_image_height * $sizefactor);
  2635.                                                 }
  2636.                                        
  2637.                                                 echo "<img src=images/avatar.png border=0 width=";
  2638.                                                 echo $pc_avatar_png_image_width;
  2639.                                                 echo " height=";
  2640.                                                 echo $pc_avatar_png_image_height;
  2641.                                         }
  2642.                                 echo "><br>";
  2643.                                 }
  2644.                                 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")) {
  2645.                                         if (file_exists("images/members/$pc_author/avatar.gif")) {
  2646.                                                 $pc_avatar_gif_image_size = getimagesize("images/members/$pc_author/avatar.gif");
  2647.                                                 $pc_avatar_gif_image_width = $pc_avatar_gif_image_size[0];
  2648.                                                 $pc_avatar_gif_image_height = $pc_avatar_gif_image_size[1];
  2649.                
  2650.                                                 $pc_max_avatar_gif_image_width = 80;
  2651.                                        
  2652.                                                 if ($pc_avatar_gif_image_width > $pc_max_avatar_gif_image_width) {  
  2653.                                                         $sizefactor = (double) ($pc_max_avatar_gif_image_width / $pc_avatar_gif_image_width) ;
  2654.                                                         $pc_avatar_gif_image_width = (int) ($pc_avatar_gif_image_width * $sizefactor);
  2655.                                                         $pc_avatar_gif_image_height = (int) ($pc_avatar_gif_image_height * $sizefactor);
  2656.                                                 }
  2657.                
  2658.                                                 echo "<img src=images/members/$pc_author/avatar.gif border=0 width=";
  2659.                                                 echo $pc_avatar_gif_image_width;
  2660.                                                 echo " height=";
  2661.                                                 echo $pc_avatar_gif_image_height;
  2662.                                         }
  2663.                                         if (file_exists("images/members/$pc_author/avatar.jpg")) {
  2664.                                                 $pc_avatar_jpg_image_size = getimagesize("images/members/$pc_author/avatar.jpg");
  2665.                                                 $pc_avatar_jpg_image_width = $pc_avatar_jpg_image_size[0];
  2666.                                                 $pc_avatar_jpg_image_height = $pc_avatar_jpg_image_size[1];
  2667.                                        
  2668.                                                 $pc_max_avatar_jpg_image_width = 80;
  2669.                                        
  2670.                                                 if ($pc_avatar_jpg_image_width > $pc_max_avatar_jpg_image_width) {  
  2671.                                                         $sizefactor = (double) ($pc_max_avatar_jpg_image_width / $pc_avatar_jpg_image_width) ;
  2672.                                                         $pc_avatar_jpg_image_width = (int) ($pc_avatar_jpg_image_width * $sizefactor);
  2673.                                                         $pc_avatar_jpg_image_height = (int) ($pc_avatar_jpg_image_height * $sizefactor);
  2674.                                                 }
  2675.                
  2676.                                                 echo "<img src=images/members/$pc_author/avatar.jpg border=0 width=";
  2677.                                                 echo $pc_avatar_jpg_image_width;
  2678.                                                 echo " height=";
  2679.                                                 echo $pc_avatar_jpg_image_height;
  2680.                                         }
  2681.                                         if (file_exists("images/members/$pc_author/avatar.png")) {
  2682.                                                 $pc_avatar_png_image_size = getimagesize("images/members/$pc_author/avatar.png");
  2683.                                                 $pc_avatar_png_image_width = $pc_avatar_png_image_size[0];
  2684.                                                 $pc_avatar_png_image_height = $pc_avatar_png_image_size[1];
  2685.                                        
  2686.                                                 $pc_max_avatar_png_image_width = 80;
  2687.                                        
  2688.                                                 if ($pc_avatar_png_image_width > $pc_max_avatar_png_image_width) {  
  2689.                                                         $sizefactor = (double) ($pc_max_avatar_png_image_width / $pc_avatar_png_image_width) ;
  2690.                                                         $pc_avatar_png_image_width = (int) ($pc_avatar_png_image_width * $sizefactor);
  2691.                                                         $pc_avatar_png_image_height = (int) ($pc_avatar_png_image_height * $sizefactor);
  2692.                                                 }
  2693.                                        
  2694.                                                 echo "<img src=images/members/$pc_author/avatar.png border=0 width=";
  2695.                                                 echo $pc_avatar_png_image_width;
  2696.                                                 echo " height=";
  2697.                                                 echo $pc_avatar_png_image_height;
  2698.                                         }
  2699.                                 echo "><br>";
  2700.                                 }
  2701.                                 echo "$pc_author</a><br>";
  2702.                                 if ((file_get_contents("data/username.txt") == $pc_author) and file_exists("data/rank.txt")) {
  2703.                                         echo "administrator<br>";
  2704.                                 }
  2705.                                 elseif (file_exists("data/members/active/$pc_author/rank.txt") and file_exists("data/rank.txt")) {
  2706.                                         $pc_rank = file_get_contents("data/members/active/$pc_author/rank.txt");
  2707.                                         echo "$pc_rank<br>";
  2708.                                 }
  2709.                                 elseif (!file_exists("data/members/active/$pc_author/rank.txt") and file_exists("data/rank.txt")) {
  2710.                                         echo "member<br>";
  2711.                                 }
  2712.                
  2713.                                 if ($pc_dh_posts = opendir("data/items")) {
  2714.                                         while (($pc_entry_posts = readdir($pc_dh_posts)) !== false) {
  2715.                
  2716.                                                 if (file_exists("data/items/$pc_entry_posts/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2717.                                                         continue;
  2718.                                                 }
  2719.                
  2720.                                                 if (file_exists("data/items/$pc_entry_posts/member.txt") and (!isset($_SESSION['logged_in']))) {
  2721.                                                         continue;
  2722.                                                 }
  2723.                
  2724.                                                 $pc_post_cat_dir = file_get_contents("data/items/$pc_entry_posts/category.txt");
  2725.                
  2726.                                                 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")) {
  2727.                                                         continue;
  2728.                                                 }
  2729.                
  2730.                                                 if ($pc_entry_posts != "." && $pc_entry_posts != ".." && fnmatch("*", $pc_entry_posts)) {
  2731.                                                         if (file_exists("data/members/active/$pc_author") and file_exists("data/bb.txt")) {
  2732.                                                                 if (file_exists("data/items/$pc_entry_posts/author.txt") and (file_get_contents("data/items/$pc_entry_posts/author.txt") == $pc_author)) {
  2733.                                                                         $pc_items_posts[] = $pc_entry_posts;
  2734.                                                                 }
  2735.                                                         }
  2736.                                                         elseif (!file_exists("data/members/active/$pc_author") and (file_get_contents("data/username.txt") == $pc_author) and file_exists("data/bb.txt")) {
  2737.                                                                 if (file_exists("data/items/$pc_entry_posts/author.txt") and (file_get_contents("data/items/$pc_entry_posts/author.txt") == $pc_author)) {
  2738.                                                                         $pc_items_posts[] = $pc_entry_posts;
  2739.                                                                 }
  2740.                                                         }
  2741.                                                 }
  2742.                                         }
  2743.                                 closedir($pc_dh_posts);
  2744.                                 }
  2745.                                 $pc_posts = count($pc_items_posts);
  2746.                                 if ($pc_posts == 1) {
  2747.                                         echo "$pc_posts post";
  2748.                                 }
  2749.                                 if ($pc_posts > 1) {
  2750.                                         echo "$pc_posts posts";
  2751.                                 }
  2752.                                 unset($pc_items_posts);
  2753.                
  2754.                                 echo "</p></td><td width=513 valign=top>";
  2755.                         }
  2756.                         else {
  2757.                                 echo "<td width=598 valign=top>";
  2758.                         }
  2759.  
  2760.                         echo '<p><font style="font-size: 10px; color: #999999;">';
  2761.                         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"))))) {
  2762.                                 $pxavatar_author = file_get_contents("$dir/$d/comments/pending/$pending_comment/author.txt");
  2763.                                 echo "<a href=member.php?id=$pxavatar_author>$pxavatar_author</a> - ";
  2764.                         }
  2765.                         readfile("$dir/$d/comments/pending/$pending_comment/timestamp.txt");
  2766.                         echo '</font><font style="font-size: 5px;"><br><br></font>';
  2767.                         readfile("$dir/$d/comments/pending/$pending_comment/comment.txt");
  2768.                         echo '</p></tr></table></div>';
  2769.                         unset($show_pending_comments);
  2770.                         echo '</td></tr></table></p>';
  2771.                 }
  2772.         }
  2773. }
  2774. ?>
  2775.  
  2776. <p><table border=0 cellspacing=0 cellpadding=0 width=100%><tr>
  2777.  
  2778. <?php
  2779. if (($start >= $increase) and ($start != 0)) {
  2780.         echo "<td align=left><p><a href=\"" . $_SERVER['PHP_SELF'] . "?";
  2781.         if (isset($_REQUEST['category']) and !empty($_REQUEST['category']) and file_exists(strip_tags(strtolower(str_replace(" ", "_", "data/categories/{$_REQUEST['category']}"))))) {
  2782.                 echo "category={$_REQUEST['category']}&";
  2783.         }
  2784.         if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  2785.                 echo "archive={$_REQUEST['archive']}&";
  2786.         }
  2787.         if (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and file_exists("data/members/active/{$_REQUEST['author']}") and file_exists("data/bb.txt")) {
  2788.                 echo "author={$_REQUEST['author']}&";
  2789.         }
  2790.         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")) {
  2791.                 echo "author={$_REQUEST['author']}&";
  2792.         }
  2793.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "private")) {
  2794.                 echo "find=private&";
  2795.         }
  2796.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "member")) {
  2797.                 echo "find=member&";
  2798.         }
  2799.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "passwd")) {
  2800.                 echo "find=passwd&";
  2801.         }
  2802.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "album")) {
  2803.                 echo "find=album&";
  2804.         }
  2805.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "filedrop")) {
  2806.                 echo "find=filedrop&";
  2807.         }
  2808.         echo "start=" . ($start-$increase) . "\">previous</a></p></td>";
  2809. }
  2810.  
  2811. if ($end < sizeof($items)) {
  2812.         echo "<td align=right><p><a href=\"" . $_SERVER['PHP_SELF'] . "?";
  2813.         if (isset($_REQUEST['category']) and !empty($_REQUEST['category']) and file_exists(strip_tags(strtolower(str_replace(" ", "_", "data/categories/{$_REQUEST['category']}"))))) {
  2814.                 echo "category={$_REQUEST['category']}&";
  2815.         }
  2816.         if (isset($_REQUEST['archive']) and !empty($_REQUEST['archive'])) {
  2817.                 echo "archive={$_REQUEST['archive']}&";
  2818.         }
  2819.         if (isset($_REQUEST['author']) and !empty($_REQUEST['author']) and file_exists("data/members/active/{$_REQUEST['author']}") and file_exists("data/bb.txt")) {
  2820.                 echo "author={$_REQUEST['author']}&";
  2821.         }
  2822.         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")) {
  2823.                 echo "author={$_REQUEST['author']}&";
  2824.         }
  2825.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "private")) {
  2826.                 echo "find=private&";
  2827.         }
  2828.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "member")) {
  2829.                 echo "find=member&";
  2830.         }
  2831.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "passwd")) {
  2832.                 echo "find=passwd&";
  2833.         }
  2834.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "album")) {
  2835.                 echo "find=album&";
  2836.         }
  2837.         if (isset($_REQUEST['find']) and !empty($_REQUEST['find']) and ($_REQUEST['find'] == "filedrop")) {
  2838.                 echo "find=filedrop&";
  2839.         }
  2840.         echo "start=" . ($start+$increase) . "\">next</a></p></td>";
  2841. }
  2842. ?>
  2843.  
  2844. </tr></table></p>
  2845.  
  2846. </td>
  2847.  
  2848. <td width=15>&nbsp;</td>
  2849. <td width=175 valign=top>
  2850.  
  2851. <?php
  2852. if ($dh_latest_items = opendir($dir)) {
  2853.         while (($entry_latest_items = readdir($dh_latest_items)) !== false) {
  2854.  
  2855.                 if (file_exists("data/items/$entry_latest_items/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2856.                         continue;
  2857.                 }
  2858.  
  2859.                 if (file_exists("data/items/$entry_latest_items/member.txt") and (!isset($_SESSION['logged_in']))) {
  2860.                         continue;
  2861.                 }
  2862.  
  2863.                 $cat_dir = file_get_contents("data/items/$entry_latest_items/category.txt");
  2864.  
  2865.                 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")) {
  2866.                         continue;
  2867.                 }
  2868.  
  2869.                 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))) {
  2870.                         continue;
  2871.                 }
  2872.  
  2873.                 if ($entry_latest_items != "." && $entry_latest_items != ".." && fnmatch("*", $entry_latest_items)) {
  2874.                         $show_latest_items[] = $entry_latest_items;
  2875.                 }
  2876.         }
  2877.         closedir($dh_latest_items);
  2878. }
  2879.  
  2880. rsort($show_latest_items);
  2881. reset($show_latest_items);
  2882. $count_latest_items = count($show_latest_items);
  2883.  
  2884. if ($count_latest_items > 0) {
  2885.  
  2886.         echo '<div id=panel_title>Recent Entries</div><div id=panel_body>';
  2887.  
  2888.         $increment_recent_entries = 0;
  2889.  
  2890.         if (($count_latest_items <= $increase) or ($count_latest_items <= $increase * 2)) {
  2891.                 $increase = $count_latest_items;
  2892.                 $show_recent_entries = $increase - 1;
  2893.         }
  2894.         else {
  2895.                 $show_recent_entries = $increase * 2 - 1;
  2896.         }
  2897.  
  2898.         while ($increment_recent_entries <= $show_recent_entries) {
  2899.                 echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' . $show_latest_items[$increment_recent_entries] . '>';
  2900.                 readfile("$dir/$show_latest_items[$increment_recent_entries]/title.txt");
  2901.                 echo '</a><br>';
  2902.                 $increment_recent_entries = $increment_recent_entries + 1;
  2903.         }
  2904. }
  2905.  
  2906. if ($count_latest_items > 0) {
  2907.         echo '</div>';
  2908. ?>
  2909.  
  2910. <?php
  2911. if (file_exists("data/bb.txt") and file_exists("data/bb-stats.txt")) {
  2912.         echo "<div id=panel_title>Bulletin Board</div><div id=panel_body>";
  2913.         if (file_exists("data/members/active") and file_exists("data/bb.txt")) {
  2914.                 if ($dh_active_list = opendir("data/members/active")) {
  2915.                         while (($entry_active_list = readdir($dh_active_list)) !== false) {
  2916.                                 if ($entry_active_list != "." && $entry_active_list != ".." && fnmatch("*", $entry_active_list)) {
  2917.                                         $show_active_list[] = $entry_active_list;
  2918.                                 }
  2919.                         }
  2920.                 closedir($dh_active_list);
  2921.                 }
  2922.  
  2923.                 sort($show_active_list);
  2924.                 reset($show_active_list);
  2925.                 $count_active_list = count($show_active_list);
  2926.                 if ($count_active_list > 0) {
  2927.                         echo "Registered Members: $count_active_list";
  2928.                 }
  2929.         }
  2930.  
  2931.  
  2932.         if (file_exists("data/items")) {
  2933.                 if ($dh_mempost_list = opendir("data/items")) {
  2934.                         while (($entry_mempost_list = readdir($dh_mempost_list)) !== false) {
  2935.  
  2936.                                 if (file_exists("data/items/$entry_mempost_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  2937.                                         continue;
  2938.                                 }
  2939.  
  2940.                                 if (file_exists("data/items/$entry_mempost_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  2941.                                         continue;
  2942.                                 }
  2943.  
  2944.                                 $get_cat_dir = file_get_contents("data/items/$entry_mempost_list/category.txt");
  2945.  
  2946.                                 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")) {
  2947.                                         continue;
  2948.                                 }
  2949.        
  2950.                                 if ($entry_mempost_list != "." && $entry_mempost_list != ".." && fnmatch("*", $entry_mempost_list)) {
  2951.                                         $entry_mempost_list = substr("$entry_mempost_list",0,6);
  2952.                                         $show_mempost_list[] = $entry_mempost_list;
  2953.                                 }
  2954.                         }
  2955.                         closedir($dh_mempost_list);
  2956.                 }
  2957.                 rsort($show_mempost_list);
  2958.                 $count_mempost_list = count($show_mempost_list);
  2959.                 echo "<br>Total Posts: $count_mempost_list";
  2960.                 unset($show_mempost_list);
  2961.         }
  2962.  
  2963.         if (file_exists("data/bb-new.txt")) {
  2964.                 $bb_new = file_get_contents("data/bb-new.txt");
  2965.                 echo "<br>Newest User: <a href=member.php?id=$bb_new>$bb_new</a>";
  2966.         }
  2967.         if (file_exists("data/bb-last.txt")) {
  2968.                 $bb_last = file_get_contents("data/bb-last.txt");
  2969.                 echo "<br>Latest Login: <a href=member.php?id=$bb_last>$bb_last</a>";
  2970.         }
  2971.         echo "</div>";
  2972. }
  2973. ?>
  2974.  
  2975. <form enctype="multipart/form-data" action="dig.php" method="post">
  2976. <div id=panel_title>Search</div>
  2977. <div id=panel_body>
  2978. <input type=text class=search name=search autocomplete=off maxlength=55>
  2979. </div>
  2980. </form>
  2981.  
  2982. <?php
  2983. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  2984.         echo "<div id=panel_title>Find Entries</div><div id=panel_body>";
  2985.         echo "<a href=index.php?find=private>Private</a>";
  2986.         if (file_exists("data/bb.txt")) {
  2987.                 echo "<br><a href=index.php?find=member>Members-Only</a>";
  2988.         }
  2989.         echo "<br><a href=index.php?find=passwd>Password Protected</a>";
  2990.         echo "<br><a href=index.php?find=filedrop>With Attached Files</a>";
  2991.         echo "<br><a href=index.php?find=album>With Photo Album</a>";
  2992.         echo "</div>";
  2993. }
  2994. ?>
  2995.  
  2996. <?php
  2997.         if (file_exists("data/categories")) {
  2998.                 if ($dh_categories = opendir("data/categories")) {
  2999.                         while (($entry_categories = readdir($dh_categories)) !== false) {
  3000.  
  3001.                                 if (file_exists("data/xcat.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3002.                                         continue;
  3003.                                 }
  3004.  
  3005.                                 if (file_exists("data/categories/$entry_categories/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3006.                                         continue;
  3007.                                 }
  3008.  
  3009.  
  3010.                                 if ($entry_categories != "." && $entry_categories != ".." && fnmatch("*", $entry_categories)) {
  3011.                                         $show_categories[] = $entry_categories;
  3012.                                 }
  3013.                         }
  3014.                         closedir($dh_categories);
  3015.                 }
  3016.  
  3017.                 sort($show_categories);
  3018.                 reset($show_categories);
  3019.                 $count_categories = count($show_categories);
  3020.  
  3021.                 if ($count_categories > 0) {
  3022.                         echo '<div id=panel_title>Categories</div><div id=panel_body>';
  3023.                         foreach ($show_categories as $category) {
  3024.                                 echo "<a href=\"" . $_SERVER['PHP_SELF'] . "?category=" . $category . "\">";
  3025.                                 if (file_exists("data/categories/$category/title.txt")) {
  3026.                                         $category_title = file_get_contents("data/categories/$category/title.txt");
  3027.                                 }
  3028.                                 else {
  3029.                                         $category_title = ucfirst(str_replace("_"," ",$category));
  3030.                                 }
  3031.                                 echo $category_title;
  3032.                                 echo "</a><br />";
  3033.                         }
  3034.                         echo '</div>';
  3035.                 }
  3036.         }
  3037.  
  3038.         if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  3039.                 echo '<div id=panel_title>Statistics</div><div id=panel_body>';
  3040.                 echo "Total Entries: $count_latest_items";
  3041.                 if (file_exists("data/hits.txt")) {
  3042.                         echo '<br>Site Hits: ';
  3043.                         readfile("data/hits.txt");
  3044.                 }
  3045.                 if (file_exists("data/google.txt")) {
  3046.                         echo '<br>Google Visits: ';
  3047.                         readfile("data/google.txt");
  3048.                 }
  3049.                 if (file_exists("data/rss-0.91.txt")) {
  3050.                         echo '<br>RSS 0.91 Hits: ';
  3051.                         readfile("data/rss-0.91.txt");
  3052.                 }
  3053.                 if (file_exists("data/rss-1.0.txt")) {
  3054.                         echo '<br>RSS 1.0 Hits: ';
  3055.                         readfile("data/rss-1.0.txt");
  3056.                 }
  3057.                 if (file_exists("data/rss-2.0.txt")) {
  3058.                         echo '<br>RSS 2.0 Hits: ';
  3059.                         readfile("data/rss-2.0.txt");
  3060.                 }
  3061.                 if (file_exists("data/sitemap.txt")) {
  3062.                         echo '<br>Sitemap Requests: ';
  3063.                         readfile("data/sitemap.txt");
  3064.                 }
  3065.  
  3066.                 echo '</div>';
  3067.         }
  3068. }
  3069.  
  3070. ?>
  3071.  
  3072.  
  3073.  
  3074. <?php
  3075. if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  3076.         if ($dh_pending_comment_flags = opendir("data/comments/pending")) {
  3077.                 while (($entry_pending_comment_flags = readdir($dh_pending_comment_flags)) !== false) {
  3078.                         if ($entry_pending_comment_flags != "." && $entry_pending_comment_flags != ".." && fnmatch("*", $entry_pending_comment_flags)) {
  3079.                                 $show_pending_comment_flags[] = $entry_pending_comment_flags;
  3080.                         }
  3081.                 }
  3082.                 closedir($dh_pending_comment_flags);
  3083.         }
  3084.  
  3085.         rsort($show_pending_comment_flags);
  3086.         reset($show_pending_comment_flags);
  3087.         $count_pending_comment_flags = count($show_pending_comment_flags);
  3088.  
  3089.         if (($count_latest_items > 0) and ($count_pending_comment_flags > 0)) {
  3090.                 echo '<div id=panel_title>Pending Comments</div>';
  3091.                 echo '<div id=panel_body>';
  3092.                 if ($dh_list_pending_comment_flags = opendir("data/comments/pending")) {
  3093.                         while (($entry_list_pending_comment_flags = readdir($dh_list_pending_comment_flags)) !== false) {
  3094.                                 if ($entry_list_pending_comment_flags != "." && $entry_list_pending_comment_flags != ".." && fnmatch("*", $entry_list_pending_comment_flags)) {
  3095.                                         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=' .$entry_list_pending_comment_flags . '&show=comments>';
  3096.                                         readfile("data/items/$entry_list_pending_comment_flags/title.txt");
  3097.                                         echo '</a><br><font style="font-size: 10px; color: #999999;">';
  3098.                                         $fp_comment_count_txt = fopen("data/comments/pending/$entry_list_pending_comment_flags/count.txt","r");
  3099.                                         $comment_count_value = fread($fp_comment_count_txt,filesize("data/comments/pending/$entry_list_pending_comment_flags/count.txt"));
  3100.                                         fclose($fp_comment_count_txt);
  3101.                                         if ($comment_count_value == 1) {
  3102.                                                 echo ' ( ' . $comment_count_value . ' comment ) ';
  3103.                                         }
  3104.                                         elseif ($comment_count_value > 1) {
  3105.                                                 echo ' ( ' . $comment_count_value . ' comments ) ';
  3106.                                         }
  3107.                                         else {
  3108.                                                 echo '';
  3109.                                         }
  3110.                                         echo '</font><br>';
  3111.                                 }
  3112.                         }
  3113.                         closedir($dh_list_pending_comment_flags);
  3114.                 }
  3115.                 echo '</div>';
  3116.         }
  3117. }
  3118. ?>
  3119.  
  3120. <?php
  3121. 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")) {
  3122.         if ($dh_pending_list = opendir("data/members/confirmed")) {
  3123.                 while (($entry_pending_list = readdir($dh_pending_list)) !== false) {
  3124.  
  3125.                         if ($entry_pending_list != "." && $entry_pending_list != ".." && fnmatch("*", $entry_pending_list)) {
  3126.                                 $show_pending_list[] = $entry_pending_list;
  3127.                         }
  3128.                 }
  3129.                 closedir($dh_pending_list);
  3130.         }
  3131.  
  3132.         sort($show_pending_list);
  3133.         reset($show_pending_list);
  3134.         $count_pending_list = count($show_pending_list);
  3135.        
  3136.         if ($count_pending_list > 0) {
  3137.                 echo "<div id=panel_title>Pending Member";
  3138.                 if ($count_pending_list > 1) {
  3139.                         echo "s";
  3140.                 }
  3141.                 echo "</div><div id=panel_body>Please approve or deny $count_pending_list pending membership request";
  3142.                 if ($count_pending_list > 1) {
  3143.                         echo "s";
  3144.                 }
  3145.                 echo " below.</div>";
  3146.                 foreach ($show_pending_list as $pending_list_entry) {
  3147.                         echo "<div id=panel_title>$pending_list_entry";
  3148.                         echo '<a href=reg.php?username=';
  3149.                         echo $pending_list_entry;
  3150.                         echo '&key=';
  3151.                         readfile("data/members/confirmed/$pending_list_entry/key.txt");
  3152.                         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=';
  3153.                         echo $pending_list_entry;
  3154.                         echo '&key=';
  3155.                         readfile("data/members/confirmed/$pending_list_entry/key.txt");
  3156.                         echo '&action=approve><img src=images/widget.cat.png border=0 width=11 height=11 align=right alt=approve></a></div>';
  3157.                         echo "<div id=panel_body>";
  3158.                         if (file_exists("data/members/confirmed/$pending_list_entry/url.txt")) {
  3159.                                 echo "<a href=\"";
  3160.                                 readfile("data/members/confirmed/$pending_list_entry/url.txt");
  3161.                                 echo "\" target=_pending>";
  3162.                         }
  3163.                         readfile("data/members/confirmed/$pending_list_entry/firstname.txt");
  3164.                         echo "&nbsp;";
  3165.                         readfile("data/members/confirmed/$pending_list_entry/lastname.txt");
  3166.                         if (file_exists("data/members/confirmed/$pending_list_entry/url.txt")) {
  3167.                                 echo "</a>";
  3168.                         }
  3169.                         echo "<br>";
  3170.                         readfile("data/members/confirmed/$pending_list_entry/email.txt");
  3171.                         if (file_exists("data/members/confirmed/$pending_list_entry/timestamp.txt")) {
  3172.                                 $confirmed = file_get_contents("data/members/confirmed/$pending_list_entry/timestamp.txt");
  3173.                                 $confirmed_year = substr($confirmed,0,4);
  3174.                                 $confirmed_month = substr($confirmed,4,2);
  3175.                                 $confirmed_day = substr($confirmed,6,2);
  3176.                                 $confirmed_hh = substr($confirmed,8,2);
  3177.                                 $confirmed_mm = substr($confirmed,10,2);
  3178.                                 $email_confirmed = date("d M Y H:i", mktime($confirmed_hh, $confirmed_mm, 0, $confirmed_month, $confirmed_day, $confirmed_year));
  3179.                                 echo "<br>$email_confirmed";
  3180.                         }
  3181.                         echo "</div>";
  3182.                 }
  3183.         }
  3184. }
  3185. ?>
  3186.  
  3187. <?php
  3188. if (file_exists("data/albums")) {
  3189.         if ($dh_album_list = opendir("data/albums")) {
  3190.                 while (($entry_album_list = readdir($dh_album_list)) !== false) {
  3191.  
  3192.                         if (file_exists("data/items/$entry_album_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3193.                                 continue;
  3194.                         }
  3195.  
  3196.                         if (file_exists("data/items/$entry_album_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  3197.                                 continue;
  3198.                         }
  3199.  
  3200.                         $pull_cat_dir = file_get_contents("data/items/$entry_album_list/category.txt");
  3201.  
  3202.                         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")) {
  3203.                                 continue;
  3204.                         }
  3205.  
  3206.                         if ($entry_album_list != "." && $entry_album_list != ".." && fnmatch("*", $entry_album_list)) {
  3207.                                 $show_album_list[] = $entry_album_list;
  3208.                         }
  3209.                 }
  3210.                 closedir($dh_album_list);
  3211.         }
  3212.  
  3213.         rsort($show_album_list);
  3214.         reset($show_album_list);
  3215.         $count_album_list = count($show_album_list);
  3216.        
  3217.         if ($count_album_list > 0) {
  3218.                 echo '<div id=panel_title>Albums</div>';
  3219.                 echo '<div id=panel_body>';
  3220.                 foreach ($show_album_list as $album_list_entry) {
  3221.                         echo '<a href=' . $_SERVER['PHP_SELF'] . '?entry=';
  3222.                         echo $album_list_entry;
  3223.                         echo '&show=album>';
  3224.                         readfile("data/items/$album_list_entry/title.txt");
  3225.                         echo '</a><br>';
  3226.                 }
  3227.                 echo '</div>';
  3228.         }
  3229. }
  3230. ?>
  3231.  
  3232.  
  3233.  
  3234. <?php
  3235. if (file_exists("data/items")) {
  3236.         if ($dh_archive_list = opendir("data/items")) {
  3237.                 while (($entry_archive_list = readdir($dh_archive_list)) !== false) {
  3238.  
  3239.                         if (file_exists("data/xarc.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3240.                                 continue;
  3241.                         }
  3242.  
  3243.                         if (file_exists("data/items/$entry_archive_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3244.                                 continue;
  3245.                         }
  3246.  
  3247.                         if (file_exists("data/items/$entry_archive_list/member.txt") and (!isset($_SESSION['logged_in']))) {
  3248.                                 continue;
  3249.                         }
  3250.  
  3251.                         $get_cat_dir = file_get_contents("data/items/$entry_archive_list/category.txt");
  3252.  
  3253.                         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")) {
  3254.                                 continue;
  3255.                         }
  3256.  
  3257.                         if ($entry_archive_list != "." && $entry_archive_list != ".." && fnmatch("*", $entry_archive_list)) {
  3258.                                 $entry_archive_list = substr("$entry_archive_list",0,6);
  3259.                                 $show_archive_list[] = $entry_archive_list;
  3260.                         }
  3261.                 }
  3262.                 closedir($dh_archive_list);
  3263.         }
  3264.  
  3265.         rsort($show_archive_list);
  3266.         reset($show_archive_list);
  3267.         $count_archive_list = count($show_archive_list);
  3268.        
  3269.         if ($count_archive_list > 0) {
  3270.  
  3271.                 $archive_entries = implode(" ",$show_archive_list);
  3272.                 $unique_archive_list = array_unique($show_archive_list);
  3273.                 echo "<div id=panel_title>Archives ($count_archive_list)</div>";
  3274.                 echo "<div id=panel_body>";
  3275.                 foreach ($unique_archive_list as $archive_list_entry) {
  3276.                         $archive_list_value = substr($archive_list_entry,0,6);
  3277.                         $archive_list_year = substr($archive_list_entry,0,4);
  3278.                         $archive_list_month = substr($archive_list_entry,4,2);
  3279.                         $archive_list_month = date("F",mktime(0,0,0,$archive_list_month));
  3280.                         echo "<a href=\"index.php?archive=$archive_list_value\">$archive_list_month $archive_list_year</a> (";
  3281.                         echo substr_count($archive_entries,$archive_list_entry);
  3282.                         echo ")<br>";
  3283.                 }
  3284.                 echo "</select></div></form>";
  3285.         }
  3286. }
  3287.  
  3288. ?>
  3289.  
  3290.  
  3291.  
  3292. <?php
  3293.  
  3294. if (file_exists("data/clustrmaps.php")) {
  3295.         echo '<div id=panel_title>ClustrMaps</div>';
  3296.         echo '<div id=panel_body><center>';
  3297.         include("data/clustrmaps.php");
  3298.         echo '</center></div>';
  3299. }
  3300. ?>
  3301.  
  3302. <?php
  3303.  
  3304. if (file_exists("data/adsense.php")) {
  3305.         echo '<div id=panel_title>AdSense</div>';
  3306.         echo '<div id=panel_body><center>';
  3307.         include("data/adsense.php");   
  3308.         echo '</center></div>';
  3309. }
  3310. ?>
  3311.  
  3312. <?php
  3313. if (file_exists("data/panels")) {
  3314.         if ($dh_right_panel_list = opendir("data/panels")) {
  3315.                 while (($entry_right_panel_list = readdir($dh_right_panel_list)) !== false) {
  3316.  
  3317.                         if (file_exists("data/panels/$entry_right_panel_list/private.txt") and (!isset($_SESSION['logged_in']) or ($_SESSION['logged_in'] != $login_username))) {
  3318.                                 continue;
  3319.                         }
  3320.  
  3321.                         if (!file_exists("data/panels/$entry_right_panel_list/right.txt")) {
  3322.                                 continue;
  3323.                         }
  3324.  
  3325.                         if ($entry_right_panel_list != "." && $entry_right_panel_list != ".." && fnmatch("*", $entry_right_panel_list)) {
  3326.                                 $show_right_panel_list[] = $entry_right_panel_list;
  3327.                         }
  3328.                 }
  3329.                 closedir($dh_right_panel_list);
  3330.         }
  3331.  
  3332.         sort($show_right_panel_list);
  3333.         reset($show_right_panel_list);
  3334.         $count_right_panel_list = count($show_right_panel_list);
  3335.        
  3336.         if ($count_right_panel_list > 0) {
  3337.                 foreach ($show_right_panel_list as $right_panel_list_entry) {
  3338.                         if (!file_exists("data/panels/$right_panel_list_entry/free.txt")) {
  3339.                                 echo '<div id=panel_title>';
  3340.                                 readfile("data/panels/$right_panel_list_entry/title.txt");
  3341.                                 if (isset($_SESSION['logged_in']) and ($_SESSION['logged_in'] == $login_username)) {
  3342.                                         echo "<a href=panels.php#{$right_panel_list_entry}>";
  3343.                                         echo '<img src=images/widget.edit.png border=0 width=11 height=11 align=right></a>';
  3344.                                 }
  3345.                                 echo '</div><div id=panel_body>';
  3346.                         }
  3347.                         if (file_exists("data/panels/$right_panel_list_entry/free.txt")) {
  3348.                                 echo '<div id=panel_free>';
  3349.                         }
  3350.                         include("data/panels/$right_panel_list_entry/panel.php");
  3351.                         echo '</div>';
  3352.                 }
  3353.         }
  3354. }
  3355. ?>
  3356.  
  3357. <?php
  3358.  
  3359. if ($count_latest_items > 0) {
  3360.         echo '<p><table border=0 cellspacing=2 cellpadding=0 width=100%>';
  3361.         echo '<tr><td align=center><a target="_button" href="http://engels.mortega.net/index.php?entry=20050521000019"><img src=images/button.maj.png border=0 width=80 height=15></a></td></tr>';
  3362.         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>';
  3363.         $validate_uri = $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']) . "/";
  3364.         $validate_uri = str_replace('//', '/', $validate_uri);
  3365.         $validate_uri = "http://" . $validate_uri;
  3366.         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>';
  3367.         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>';
  3368.         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>';
  3369.         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>';
  3370.         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>';
  3371.         if (file_exists("data/sfx.txt")) {
  3372.                 $fp_sfx = fopen("data/sfx.txt", "r");
  3373.                 $sfx = fread($fp_sfx, filesize("data/sfx.txt"));
  3374.                 fclose($fp_sfx);
  3375.                 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>';
  3376.         }
  3377.         echo '</table></p>';
  3378.  
  3379. }
  3380.  
  3381. ?>
  3382.  
  3383. <p></p>
  3384.  
  3385. </td></tr>
  3386. </table>
  3387.  
  3388. <?php
  3389. if (file_exists("footer.php")) {
  3390.         echo '<p></p>';
  3391.         include("footer.php");
  3392. }
  3393. ?>
  3394.  
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