memo/pukiwiki
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
単語検索
|
最終更新
|
ヘルプ
]
開始行:
*pukiwiki [#geed59c4]
2014/11/12にレンタルスペースであるusamimi.infoさんのPHPバ...
それに伴い当pukiwikiのプラグインの設定や本体の設定をメモ...
#contents
**pukiwiki.ini.php [#ga76b1d3]
-$script_directory_index
- //$script_directory_index = 'index.php';
+ $script_directory_index = 'index.php';
-$modifier
- $modifier = 'anonymous';
+ $modifier = 'シンプルなスクーターサイト';
-$modifierlink
- $modifierlink = 'http://pukiwiki.example.com/';
+ $modifierlink = 'http://www.usamimi.info/~who/';
-$defaultpage
- $defaultpage = 'FrontPage'; // Top / Default page
+ $defaultpage = 'シンプルなスクーターサイト'; // T...
-$nowikiname
- $nowikiname = 0;
+ $nowikiname = 1;
**default.ini.php [#m3b68244]
-$attach_link
- $attach_link = 1;
+ $attach_link = 0;
-$related_link
- $related_link = 1;
+ $related_link = 0;
**/lib/make_link.php [#xa3da93a]
-class Link_url extends Link~
364行辺り
function Link_url($start)
{
parent::Link($start);
}
function get_pattern()
{
$s1 = $this->start + 1;
return <<<EOD
(\[\[ # (1) open bracket
((?:(?!\]\]).)+) # (2) alias
(?:>|:)
)?
( # (3) url
- (?:(?:https?|ftp|news):\/\/|mailto:)[\w\/\@\$()!?&%#:;...
+ (?:(?:\+?https?|\+?ftp|\+?news):\/\/|mailto:)[\w\/\@\$...
)
(?($s1)\]\]) # close bracket
EOD;
381行辺り
function toString()
{
if (FALSE) {
$rel = '';
} else {
$rel = ' rel="nofollow"';
}
+ if (ereg("^(\+)(.*)", $this->name, $regs)) {
+ return '<a href="' . $regs[2] . '" target="_blank" ...
+ }else{
return '<a href="' . $this->name . '"' . $rel . '>' . ...
+ }
}
[[PukiWiki別窓リンク:http://www.ns-lab.org/wiki/?PukiWiki...
**/lib/file.php [#x2de2606]
[[美麻wikiさんより引用:http://www.miasa.info/index.php?%C...
// Create and write diff
$oldpostdata = is_page($page) ? join('', get_source($pa...
$diffdata = do_diff($oldpostdata, $postdata);
+ // add client info
+ global $now;
+ $referer = htmlspecialchars($_SERVER['HTTP_REFERER']);
+ $user_agent = htmlspecialchars($_SERVER['HTTP_USER_AGE...
+ $diffdata .= "IP:{$_SERVER['REMOTE_ADDR']} TIME:\"$now...
file_write(DIFF_DIR, $page, $diffdata);
// Create backup
**/lib/init.php [#i5b3c7da]
[[美麻wikiさんより引用:http://www.miasa.info/index.php?%C...
$user_agent = $matches = array();
$user_agent['agent'] = isset($_SERVER['HTTP_USER_AGENT']...
-unset(${$ua}, $_SERVER[$ua], $HTTP_SERVER_VARS[$ua], $u...
+//unset(${$ua}, $_SERVER[$ua], $HTTP_SERVER_VARS[$ua], ...
foreach ($agents as $agent) {
if (preg_match($agent['pattern'], $user_agent['agent'],...
break;
}
}
-unset($agents, $matches);
+//unset($agents, $matches);
// Profile-related init and setting
define('UA_PROFILE', isset($user_agent['profile']) ? $us...
**/skin/pukiwiki.skin.php [#qb727896]
-SKIN_DEFAULT_DISABLE_TOPICPATH
if (! defined('SKIN_DEFAULT_DISABLE_TOPICPATH'))
- define('SKIN_DEFAULT_DISABLE_TOPICPATH', 1); // 1, 0
+ define('SKIN_DEFAULT_DISABLE_TOPICPATH', 0); // 1, 0
-SKIN_DEFAULT_DISABLE_TOPICPATH~
プラグインs.inc.php導入により加筆修正
<?php if ($is_page) { ?>
<?php if(SKIN_DEFAULT_DISABLE_TOPICPATH) { ?>
<a href="<?php echo $link['reload'] ?>"><span class="...
<?php } else { ?>
<span class="small">
- <?php require_once(PLUGIN_DIR . 'topicpath.inc.php');...
+ <?php require_once(PLUGIN_DIR . 'topicpath.inc.php');...
+ <?php require_once(PLUGIN_DIR . 's.inc.php'); echo pl...
</span>
<?php } ?>
<?php } ?>
**/plugin/ [#q7f63ad3]
***s.inc.php [#gd6986b7]
導入~
***number.inc.php [#td450ddc]
導入~
***topicpath.inc.php [#yb15bf4b]
-38行目
- if ($page == '' || $page == $defaultpage) return '';
+ if ($page == '' || $page == $defaultpage) return PLUGI...
-PLUGIN_TOPICPATH_TOP_DISPLAY
- $topic_path[] = make_pagelink($defaultpage, PLUGIN_TOP...
+ $topic_path[] = '<a href="' . $script . '">' . PLUGIN_...
終了行:
*pukiwiki [#geed59c4]
2014/11/12にレンタルスペースであるusamimi.infoさんのPHPバ...
それに伴い当pukiwikiのプラグインの設定や本体の設定をメモ...
#contents
**pukiwiki.ini.php [#ga76b1d3]
-$script_directory_index
- //$script_directory_index = 'index.php';
+ $script_directory_index = 'index.php';
-$modifier
- $modifier = 'anonymous';
+ $modifier = 'シンプルなスクーターサイト';
-$modifierlink
- $modifierlink = 'http://pukiwiki.example.com/';
+ $modifierlink = 'http://www.usamimi.info/~who/';
-$defaultpage
- $defaultpage = 'FrontPage'; // Top / Default page
+ $defaultpage = 'シンプルなスクーターサイト'; // T...
-$nowikiname
- $nowikiname = 0;
+ $nowikiname = 1;
**default.ini.php [#m3b68244]
-$attach_link
- $attach_link = 1;
+ $attach_link = 0;
-$related_link
- $related_link = 1;
+ $related_link = 0;
**/lib/make_link.php [#xa3da93a]
-class Link_url extends Link~
364行辺り
function Link_url($start)
{
parent::Link($start);
}
function get_pattern()
{
$s1 = $this->start + 1;
return <<<EOD
(\[\[ # (1) open bracket
((?:(?!\]\]).)+) # (2) alias
(?:>|:)
)?
( # (3) url
- (?:(?:https?|ftp|news):\/\/|mailto:)[\w\/\@\$()!?&%#:;...
+ (?:(?:\+?https?|\+?ftp|\+?news):\/\/|mailto:)[\w\/\@\$...
)
(?($s1)\]\]) # close bracket
EOD;
381行辺り
function toString()
{
if (FALSE) {
$rel = '';
} else {
$rel = ' rel="nofollow"';
}
+ if (ereg("^(\+)(.*)", $this->name, $regs)) {
+ return '<a href="' . $regs[2] . '" target="_blank" ...
+ }else{
return '<a href="' . $this->name . '"' . $rel . '>' . ...
+ }
}
[[PukiWiki別窓リンク:http://www.ns-lab.org/wiki/?PukiWiki...
**/lib/file.php [#x2de2606]
[[美麻wikiさんより引用:http://www.miasa.info/index.php?%C...
// Create and write diff
$oldpostdata = is_page($page) ? join('', get_source($pa...
$diffdata = do_diff($oldpostdata, $postdata);
+ // add client info
+ global $now;
+ $referer = htmlspecialchars($_SERVER['HTTP_REFERER']);
+ $user_agent = htmlspecialchars($_SERVER['HTTP_USER_AGE...
+ $diffdata .= "IP:{$_SERVER['REMOTE_ADDR']} TIME:\"$now...
file_write(DIFF_DIR, $page, $diffdata);
// Create backup
**/lib/init.php [#i5b3c7da]
[[美麻wikiさんより引用:http://www.miasa.info/index.php?%C...
$user_agent = $matches = array();
$user_agent['agent'] = isset($_SERVER['HTTP_USER_AGENT']...
-unset(${$ua}, $_SERVER[$ua], $HTTP_SERVER_VARS[$ua], $u...
+//unset(${$ua}, $_SERVER[$ua], $HTTP_SERVER_VARS[$ua], ...
foreach ($agents as $agent) {
if (preg_match($agent['pattern'], $user_agent['agent'],...
break;
}
}
-unset($agents, $matches);
+//unset($agents, $matches);
// Profile-related init and setting
define('UA_PROFILE', isset($user_agent['profile']) ? $us...
**/skin/pukiwiki.skin.php [#qb727896]
-SKIN_DEFAULT_DISABLE_TOPICPATH
if (! defined('SKIN_DEFAULT_DISABLE_TOPICPATH'))
- define('SKIN_DEFAULT_DISABLE_TOPICPATH', 1); // 1, 0
+ define('SKIN_DEFAULT_DISABLE_TOPICPATH', 0); // 1, 0
-SKIN_DEFAULT_DISABLE_TOPICPATH~
プラグインs.inc.php導入により加筆修正
<?php if ($is_page) { ?>
<?php if(SKIN_DEFAULT_DISABLE_TOPICPATH) { ?>
<a href="<?php echo $link['reload'] ?>"><span class="...
<?php } else { ?>
<span class="small">
- <?php require_once(PLUGIN_DIR . 'topicpath.inc.php');...
+ <?php require_once(PLUGIN_DIR . 'topicpath.inc.php');...
+ <?php require_once(PLUGIN_DIR . 's.inc.php'); echo pl...
</span>
<?php } ?>
<?php } ?>
**/plugin/ [#q7f63ad3]
***s.inc.php [#gd6986b7]
導入~
***number.inc.php [#td450ddc]
導入~
***topicpath.inc.php [#yb15bf4b]
-38行目
- if ($page == '' || $page == $defaultpage) return '';
+ if ($page == '' || $page == $defaultpage) return PLUGI...
-PLUGIN_TOPICPATH_TOP_DISPLAY
- $topic_path[] = make_pagelink($defaultpage, PLUGIN_TOP...
+ $topic_path[] = '<a href="' . $script . '">' . PLUGIN_...
ページ名: