PukiWiki/編集者限定Top / PukiWiki / 編集者限定
comment だけ許可これだと editable でない方でコメントを付けたときに日付が更新されない。 index.php define('PKWK_ALLOW_COMMENT', 1); plugin/comment.inc.php if (PKWK_READONLY) ↓ if (PKWK_READONLY && !PKWK_ALLOW_COMMENT) page_write($vars['refer'], $postdata); ↓ page_write($vars['refer'], $postdata, FALSE, TRUE); lib/file.php function page_write($page, $postdata, $notimestamp=FALSE, $allow_write=FALSE) if (PKWK_READONLY && !(PKWK_ALLOW_COMMENT && $allow_write)) return; // Do nothing file_write(DIFF_DIR, $page, $diffdata, $notimestamp, $allow_write); file_write(DATA_DIR, $page, $postdata, $notimestamp, $allow_write); function file_write($dir, $page, $str, $notimestamp=FALSE, $allow_write=FALSE) if (PKWK_READONLY && !(PKWK_ALLOW_COMMENT && $allow_write)) return; // Do nothing put_lastmodified(PKWK_ALLOW_COMMENT && $allow_write); function put_lastmodified($ignore_readonly=FALSE) if (PKWK_READONLY && !$ignore_readonly) return; // Do nothing |