[P2-php-svn] [832] expack:

アーカイブの一覧に戻る

svnno****@sourc***** svnno****@sourc*****
2010年 2月 10日 (水) 12:23:48 JST


Revision: 832
          http://sourceforge.jp/projects/p2-php/svn/view?view=rev&revision=832
Author:   rsk
Date:     2010-02-10 12:23:48 +0900 (Wed, 10 Feb 2010)

Log Message:
-----------
expack:
- iPhoneでお気に板の登録ができない不具合を修正。
- E_NOTICE削減中。

Modified Paths:
--------------
    p2ex/trunk/js/menu_i.js
    p2ex/trunk/lib/subject_new.inc.php
    p2ex/trunk/read_res_hist.php


-------------- next part --------------
Modified: p2ex/trunk/js/menu_i.js
===================================================================
--- p2ex/trunk/js/menu_i.js	2010-02-01 17:05:26 UTC (rev 831)
+++ p2ex/trunk/js/menu_i.js	2010-02-10 03:23:48 UTC (rev 832)
@@ -131,6 +131,7 @@
 	var setFavita = function(div) {
 		var toggled, req, uri, setnum;
 
+		toggled = div.getAttribute('toggled') === 'true';
 		setnum = parseInt(div.className.substring(div.className.indexOf('favita') + 6));
 		uri = 'httpcmd.php?cmd=setfavita&' + window.iutil.sliding.query + '&setnum=' + setnum;
 		if (toggled) {
@@ -139,7 +140,6 @@
 			uri += '&setfavita=0';
 		}
 
-		toggled = div.getAttribute('toggled') === 'true';
 		req = new XMLHttpRequest();
 		req.open('GET', uri, true);
 		req.onreadystatechange = generateOnToggle(req, div, toggled);

Modified: p2ex/trunk/lib/subject_new.inc.php
===================================================================
--- p2ex/trunk/lib/subject_new.inc.php	2010-02-01 17:05:26 UTC (rev 831)
+++ p2ex/trunk/lib/subject_new.inc.php	2010-02-10 03:23:48 UTC (rev 832)
@@ -16,12 +16,14 @@
     $spmode = false;
 }
 
+$idx_host_bbs_dir_s = P2Util::idxDirOfHostBbs($host, $bbs);
+$p2_sb_keys_txt = $idx_host_bbs_dir_s . 'p2_sb_keys.txt';
+$p2_setting_txt = $idx_host_bbs_dir_s . 'p2_setting.txt';
+
 // {{{ sb_keys Ý’è
 
 if (!$spmode) {
-    $sb_keys_txt = P2Util::idxDirOfHostBbs($host, $bbs) . 'p2_sb_keys.txt';
-
-    if ($pre_sb_cont = FileCtl::file_read_contents($sb_keys_txt)) {
+    if ($pre_sb_cont = FileCtl::file_read_contents($p2_sb_keys_txt)) {
         $pre_subject_keys = @unserialize($pre_sb_cont);
         if (!is_array($pre_subject_keys)) {
             $pre_subject_keys = array();
@@ -35,7 +37,21 @@
 }
 
 // }}}
+// {{{ itaj Ý’è
 
+$itaj = null;
+if ($p2_setting_cont = FileCtl::file_read_contents($p2_setting_txt)) {
+    $p2_setting = @unserialize($p2_setting_cont);
+    if (is_array($p2_setting) && array_key_exists('itaj', $p2_setting)) {
+        $itaj = $p2_setting['itaj'];
+    }
+}
+if ($itaj === null || $itaj === '') {
+    $itaj = P2Util::getItaName($host, $bbs);
+}
+
+// }}}
+
 //============================================================
 // ƒƒCƒ“
 //============================================================
@@ -44,13 +60,12 @@
 
 // ”‚ƃ‚[ƒh‚̃Zƒbƒg ===================================
 if ($spmode) {
-    if ($spmode == "taborn" or $spmode == "soko") {
-        $aThreadList->setIta($host, $bbs, P2Util::getItaName($host, $bbs));
+    if ($spmode == 'taborn' or $spmode == 'soko') {
+        $aThreadList->setIta($host, $bbs, $itaj);
     }
     $aThreadList->setSpMode($spmode);
 } else {
-    // if(!$p2_setting['itaj']){$p2_setting['itaj'] = P2Util::getItaName($host, $bbs);}
-    $aThreadList->setIta($host, $bbs, $p2_setting['itaj']);
+    $aThreadList->setIta($host, $bbs, $itaj);
 
     // ƒXƒŒƒbƒh‚ ‚ځ[‚ñƒŠƒXƒg“Ǎž
     $taborn_file = $aThreadList->getIdxDir() . 'p2_threads_aborn.idx';

Modified: p2ex/trunk/read_res_hist.php
===================================================================
--- p2ex/trunk/read_res_hist.php	2010-02-01 17:05:26 UTC (rev 831)
+++ p2ex/trunk/read_res_hist.php	2010-02-10 03:23:48 UTC (rev 832)
@@ -21,7 +21,7 @@
 // “ÁŽê‚È‘O’uˆ—
 //================================================================
 // íœ
-if ($_POST['submit'] == $deletemsg_st or isset($_GET['checked_hists'])) {
+if ((isset($_POST['submit']) && $_POST['submit'] == $deletemsg_st) or isset($_GET['checked_hists'])) {
     $checked_hists = array();
     if (isset($_POST['checked_hists'])) {
         $checked_hists = $_POST['checked_hists'];



P2-php-svn メーリングリストの案内
アーカイブの一覧に戻る