maj.world

maj.world

Git

This blob has been accessed 425 times via Git panel.

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