X-Git-Url: http://4ch.mooo.com/gitweb/?a=blobdiff_plain;f=yotsubanome.php;h=4b0b3d11a509e625e481ecd08556f4c233a6fc4a;hb=94f1faa6e2a3e0aca3f9bfdca2e6afef4393c354;hp=fd165348972d3d73c158d0a929a2da64ff6776d3;hpb=5e244045b46555605d0422884c89ee6404820bca;p=test.git
diff --git a/yotsubanome.php b/yotsubanome.php
index fd16534..4b0b3d1 100755
--- a/yotsubanome.php
+++ b/yotsubanome.php
@@ -57,14 +57,9 @@ error_reporting(E_ALL); // show all errors for debugging
/* Enviorment Settings */
// Do not change unless you renamed the directories
define("PHP_DIRECTORY", '../test/'); // yotsubanome "C:\windows\system\"
-define("DATA_DIR", PHP_DIRECTORY.'data/'); // data directory
-define("CSS_DIR", DATA_DIR.'css/'); // CSS directory
-define("ICON_DIR", DATA_DIR.'icon/'); // icon directory [Graphics of the software go here]
-define("TEMP_DIR", PHP_DIRECTORY.'temp/'); // upload content temperary directory
-define("TPLT_DIR", DATA_DIR.'tplt/'); // template directory
-define("JS_DIR", DATA_DIR.'js/'); // javascript directory
-define("SALTFILE", DATA_DIR.'salt.php'); // saltfile for secure t. codes
+/* Include */
+include_once(PHP_DIRECTORY.'env.php'); // Enviorment Settings
include_once(PHP_DIRECTORY.'config.php'); // å¼å
¥è¨å®æª
include_once(PHP_DIRECTORY.'lib/lib_language.php'); // å¼å
¥èªç³»
include_once(PHP_DIRECTORY.'lib/lib_common.php'); // å¼å
¥å
±éå½å¼æªæ¡
@@ -305,7 +300,8 @@ function arrangeThread($PTE, $tree, $tree_cut, $posts, $hiddenReply, $resno=0, $
if(gettype($tree_cut) == 'array') $tree_cut = array_flip($tree_cut); // array_flip + isset æå°æ³
if(gettype($tree) == 'array') $tree_clone = array_flip($tree);
if($hiddenReply){ // o++
- // $o = 0 (é¦ç¯), $o = 1ï½n (åæ) //++++----
for($o = 0; $o < $posts_img_count; $o++){ // o++
+ // $o = 0 (é¦ç¯), $o = 1ï½n (åæ) //++++----
+ for($o = 0; $o < $posts_img_count; $o++){ // o++
extract($posts_img[$o]); // o++
if($ext && $FileIO->imageExists($tim.$ext)) $hiddenImage++; // o++ all images in thread
}
@@ -332,7 +328,8 @@ function arrangeThread($PTE, $tree, $tree_cut, $posts, $hiddenReply, $resno=0, $
// è¨å®æ¬ä½å¼
$name = str_replace('&'.TRIP_KEY, '&'.TRIP_KEY, $name); // é¿å
xxx; å¾é¢è¢«è¦çº Trip çä¸ & é æ解æé¯èª¤
if(CLEAR_SAGE) $email = preg_replace('/^sage( *)/i', '', trim($email)); // æ¸
é¤E-mailä¸çãsageãééµå
- //Tripcode indicator // t++ //++++----
+ // Tripcode indicator // t++ //++++----
+ // This may be a blob of code but it apparently works >< please help me here
$tripkeycount = substr_count($name, TRIP_KEY);
if(ALLOW_NONAME==2){ // å¼·å¶ç å
if($tripkeycount==1) $name = preg_match('/(\\'.TRIP_KEY.'.{10})/', $name, $matches) ? ''.$matches[1].'' : '';
@@ -418,6 +415,7 @@ function arrangeThread($PTE, $tree, $tree_cut, $posts, $hiddenReply, $resno=0, $
if($flgh->exists('TS')) $WARN_ENDREPLY = ''._T('warn_locked').'
'."\n"; // 被æ¨è¨çºç¦æ¢åæ
if($hiddenReply) $WARN_HIDEPOST = ''._res($hiddenReply, $hiddenImgs)._T('notice_omitted_reply').'
'."\n"; // æé±èçåæ
}
+
// å°é¡å¥æ¨ç±¤ä½èªåé£çµ
if(USE_CATEGORY){
$ary_category = explode(',', str_replace(',', ',', $category)); $ary_category = array_map('trim', $ary_category);
@@ -561,7 +559,7 @@ function regist(){
$size = @getimagesize($dest);
if(!is_array($size)) error(_T('regist_upload_notimage'), $dest); // $sizeä¸çºé£åå°±ä¸æ¯åæª
$imgsize = @filesize($dest); // æªæ¡å¤§å°
- if(!KB) $imgsize .= ' B'; // B only
+ if(!KB) $imgsize .= ' B'; // Bytes only
else $imgsize = ($imgsize>=1024) ? (int)($imgsize/1024).' KB' : $imgsize.' B'; // KBåBçå¤å¥
switch($size[2]){ // å¤æ·ä¸å³éå åæªä¹æ ¼å¼
case 1 : $ext = ".gif"; break;
@@ -579,7 +577,7 @@ function regist(){
case 13 : $ext = ".swf"; break;
case 14 : $ext = ".aiff"; break;
case 15 : $ext = ".wbmp"; break;
- case 16 : $ext = ".xbm"; break;
+ case 16 : $ext = ".xbm"; break; // I add more media support (^^,)
default : $ext = ".xxxx"; error(_T('regist_upload_notsupport'), $dest);
}
$allow_exts = explode('|', strtolower(ALLOW_UPLOAD_EXT)); // æ¥åä¹éå åæªå¯æªå
@@ -588,7 +586,7 @@ function regist(){
$md5chksum = md5_file($dest); // æªæ¡MD5
if(array_search($md5chksum, $BAD_FILEMD5)!==FALSE) error(_T('regist_upload_blocked'), $dest); // å¨å°éè¨å®å
§åé»æ
- // åâ§è¨ç®éå åæªåæªç¸®å顯示尺寸
+ // åâ§è¨ç®éå åæªåæªç¸®å顯示尺寸 //++++---- <- the comment from pixmicat team is broken here
$W = $imgW = $size[0];
$H = $imgH = $size[1];
$MAXW = $resto ? MAX_RW : MAX_W;
@@ -611,6 +609,7 @@ function regist(){
// E-mail / æ¨é¡ä¿®æ´
$email = str_replace("\r\n", '', $email); $sub = str_replace("\r\n", '', $sub);
+
// Tripcode area--------------------------------------------------------------------------------
if($name){
// å稱修æ´