maj.world

maj.world

Git

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