/** * コンストラクタ */ public function __construct($aThread, $matome = false) { parent::__construct($aThread, $matome); global $_conf; $this->_url_handlers = array('plugin_linkThread', 'plugin_link2chSubject'); if (P2_IMAGECACHE_AVAILABLE == 2) { $this->_url_handlers[] = 'plugin_imageCache2'; } elseif ($_conf['preview_thumbnail']) { $this->_url_handlers[] = 'plugin_viewImage'; } if ($_conf['link_youtube']) { $this->_url_handlers[] = 'plugin_linkYouTube'; } if ($_conf['link_niconico']) { $this->_url_handlers[] = 'plugin_linkNicoNico'; } $this->_url_handlers[] = 'plugin_linkURL'; // サムネイル表示制限数を設定 if (!isset($GLOBALS['pre_thumb_unlimited']) || !isset($GLOBALS['pre_thumb_limit'])) { if (isset($_conf['pre_thumb_limit']) && $_conf['pre_thumb_limit'] > 0) { $GLOBALS['pre_thumb_limit'] = $_conf['pre_thumb_limit']; $GLOBALS['pre_thumb_unlimited'] = FALSE; } else { $GLOBALS['pre_thumb_limit'] = NULL; // ヌル値だとisset()はFALSEを返す $GLOBALS['pre_thumb_unlimited'] = TRUE; } } $GLOBALS['pre_thumb_ignore_limit'] = FALSE; // アクティブモナー初期化 if (P2_ACTIVEMONA_AVAILABLE) { ExpackLoader::initActiveMona($this); } // ImageCache2初期化 if (P2_IMAGECACHE_AVAILABLE == 2) { ExpackLoader::initImageCache($this); } // 非同期レスポップアップ・SPM初期化 $js_id = sprintf('%u', crc32($this->thread->keydat)); if ($this->_matome) { $this->asyncObjName = "t{$this->_matome}asp{$js_id}"; $this->spmObjName = "t{$this->_matome}spm{$js_id}"; } else { $this->asyncObjName = "asp{$js_id}"; $this->spmObjName = "spm{$js_id}"; } }
/** * コンストラクタ */ public function __construct(ThreadRead $aThread, $matome = false) { parent::__construct($aThread, $matome); global $_conf, $STYLE; if ($_conf['iphone']) { $this->respopup_at = ' onclick="return iResPopUp(this, event);"'; $this->target_at = ' target="_blank"'; $this->check_st = 'check'; } $this->_url_handlers = array('plugin_linkThread', 'plugin_link2chSubject'); if (P2_IMAGECACHE_AVAILABLE == 2) { $this->_url_handlers[] = 'plugin_imageCache2'; } elseif ($_conf['mobile.use_picto']) { $this->_url_handlers[] = 'plugin_viewImage'; } if ($_conf['mobile.link_youtube']) { $this->_url_handlers[] = 'plugin_linkYouTube'; } $this->_url_handlers[] = 'plugin_linkURL'; if (!$_conf['mobile.bbs_noname_name']) { $st = new SettingTxt($this->thread->host, $this->thread->bbs); $st->setSettingArray(); if (array_key_exists('BBS_NONAME_NAME', $st->setting_array)) { $BBS_NONAME_NAME = $st->setting_array['BBS_NONAME_NAME']; if (strlen($BBS_NONAME_NAME)) { $this->_nanashiName = $BBS_NONAME_NAME; } } } if (P2Util::isHost2chs($aThread->host)) { $this->_kushiYakiName = ' </b>[—\{}@{}@{}-]<b> '; } if ($_conf['mobile.date_zerosuppress']) { $this->_dateIdPattern = '~^(?:' . date('Y|y') . ')/(?:0(\\d)|(\\d\\d))?(?:(/)0)?~'; $this->_dateIdReplace = '$1$2$3'; } else { $this->_dateIdPattern = '~^(?:' . date('Y|y') . ')/~'; $this->_dateIdReplace = ''; } // 連続する改行の置換文字列を設定 /* if ($_conf['mobile.strip_linebreaks']) { $ngword_color = $GLOBALS['STYLE']['mobile_read_ngword_color']; if (strpos($ngword_color, '\\') === false && strpos($ngword_color, '$') === false) { $this->_lineBreaksReplace = " <br><s><font color=\"{$ngword_color}\">***</font></s><br> "; } else { $this->_lineBreaksReplace = ' <br><s>***</s><br> '; } } else { $this->_lineBreaksReplace = null; } */ // サムネイル表示制限数を設定 if (!isset($GLOBALS['pre_thumb_unlimited']) || !isset($GLOBALS['expack.ic2.pre_thumb_limit_k'])) { if (isset($_conf['expack.ic2.pre_thumb_limit_k']) && $_conf['expack.ic2.pre_thumb_limit_k'] > 0) { $GLOBALS['pre_thumb_limit_k'] = $_conf['expack.ic2.pre_thumb_limit_k']; $GLOBALS['pre_thumb_unlimited'] = false; } else { $GLOBALS['pre_thumb_limit_k'] = null; // ヌル値だとisset()はFALSEを返す $GLOBALS['pre_thumb_unlimited'] = true; } } $GLOBALS['pre_thumb_ignore_limit'] = false; // アクティブモナー初期化 if (P2_ACTIVEMONA_AVAILABLE) { ExpackLoader::initActiveMona($this); } // ImageCache2初期化 if (P2_IMAGECACHE_AVAILABLE == 2) { ExpackLoader::initImageCache($this); } // AAS 初期化 if (P2_AAS_AVAILABLE) { ExpackLoader::initAAS($this); } // SPM初期化 //if ($this->_matome) { // $this->spmObjName = sprintf('t%dspm%u', $this->_matome, crc32($this->thread->keydat)); //} else { $this->spmObjName = sprintf('spm%u', crc32($this->thread->keydat)); //} }
/** * コンストラクタ */ public function __construct($aThread, $matome = false) { parent::__construct($aThread, $matome); global $_conf; $this->_url_handlers = array('plugin_linkThread', 'plugin_link2chSubject'); // +Wiki if (isset($GLOBALS['linkPluginCtl'])) { $this->_url_handlers[] = 'plugin_linkPlugin'; } if (isset($GLOBALS['replaceImageUrlCtl'])) { $this->_url_handlers[] = 'plugin_replaceImageUrl'; } if (P2_IMAGECACHE_AVAILABLE == 2) { $this->_url_handlers[] = 'plugin_imageCache2'; } elseif ($_conf['preview_thumbnail']) { $this->_url_handlers[] = 'plugin_viewImage'; } if ($_conf['link_youtube']) { $this->_url_handlers[] = 'plugin_linkYouTube'; } if ($_conf['link_niconico']) { $this->_url_handlers[] = 'plugin_linkNicoNico'; } $this->_url_handlers[] = 'plugin_linkURL'; // imepitaのURLを加工してImageCache2させるプラグインを登録 if (P2_IMAGECACHE_AVAILABLE == 2) { $this->addURLHandler(array($this, 'plugin_imepitaToImageCache2')); } // サムネイル表示制限数を設定 if (!isset($GLOBALS['pre_thumb_unlimited']) || !isset($GLOBALS['pre_thumb_limit'])) { if (isset($_conf['pre_thumb_limit']) && $_conf['pre_thumb_limit'] > 0) { $GLOBALS['pre_thumb_limit'] = $_conf['pre_thumb_limit']; $GLOBALS['pre_thumb_unlimited'] = false; } else { $GLOBALS['pre_thumb_limit'] = null; // ヌル値だとisset()はfalseを返す $GLOBALS['pre_thumb_unlimited'] = true; } } $GLOBALS['pre_thumb_ignore_limit'] = false; // アクティブモナー初期化 if (P2_ACTIVEMONA_AVAILABLE) { ExpackLoader::initActiveMona($this); } // ImageCache2初期化 if (P2_IMAGECACHE_AVAILABLE == 2) { ExpackLoader::initImageCache($this); } // 非同期レスポップアップ・SPM初期化 $js_id = sprintf('%u', crc32($this->thread->keydat)); if ($this->_matome) { $this->asyncObjName = "t{$this->_matome}asp{$js_id}"; $this->spmObjName = "t{$this->_matome}spm{$js_id}"; } else { $this->asyncObjName = "asp{$js_id}"; $this->spmObjName = "spm{$js_id}"; } // 名無し初期化 $this->setBbsNonameName(); }