[外掛]訪客限制plus ~by 御津闇慈發佈
http://phpbb-tw.net/phpbb/viewtopic.php?t=30245
(注意,此外掛最後更新是2005-01-01 18:26.
前言:
相信有很多人都一直為了BOT和保護會員的資料出了不少的心機, 裝了最少幾種安全性的外掛
為了統一和更加強力地管理論壇瀏覽的權限, 這一支外掛就你需要裝的啦^^
外掛狀態: 目前此外掛處於長期更新,仍然有不少的BUG, 作者drathbun請你遇到時提出!
代碼: 選擇全部
##############################################################
## MOD Title: Page Permissions
## MOD Author: drathbun < N/A > (Dave Rathbun) http://www.phpBBDoctor.com
## MOD Description: Set permissions by page (guest, reg, private, mod, admin)
## MOD Version: 1.0.0
##
##
## Installation Level: Easy
## Installation Time: ~ 5 Minutes
## Files To Edit: includes/constants.php, includes/functions.php, language/lang_english/lang_admin.php, language/lang_english/lang_main.php
## Included Files: cache_pages.php, admin_page_permissions.php, phpbbdoctor_cache_functions.php, page_permissions.php, page_permissions_list_body.tpl, page_permissions_edit_body.tpl
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2
##############################################################
## For security purposes, please check: http://www.phpbb.com/mods/
## for the latest version of this MOD. Although MODs are checked
## before being allowed in the MODs Database there is no guarantee
## that there are no security problems within the MOD. No support
## will be given for MODs not found within the MODs Database which
## can be found at http://www.phpbb.com/mods/
##############################################################
就如前言所說, 你安裝了以後將可以更強力地管理權限。
1. Disable (禁止)lets you take a page offline without taking your entire board offline.
很多時候大家都會在論壇仍然運作的時候或者有會員瀏覽上線的時候在忙碌更新一些頁面。
比如說你在更新viewforum.php+viewfourm_body.tpl, 你可以利用這支外掛去標明說: "對不起, 目前這頁面禁止瀏覽"
2. Admin Required
If you want a page to require admin level access at all times, mark it so. Guests, users, and even moderators will get an "insufficient privileges" message when they attempt to access the page.
竹貓裡經常有站長查詢關於"會員資料", 和禁止訪客等等在論壇裡活躍, 以前就需要裝一些簡單但是功能很分散的外掛
當你安裝這個外掛以後, 你將可以在後台裡, 設定瀏覽頁面的等級權限。
但是這功能本來在phpBB就已經有啦? 不過那個功能只是把論壇裡的頁面!
比如說小竹子不希望普通會員瀏覽竹貓星球的會員列表, 這支外掛主要是完全禁止"disable"瀏覽頁面。
會員列表在程式中是叫 "memeberlist.php"
只要在後台設定memeberlist.php→需要系統管理員權限, 這樣子連板主也不會看到會員列表.......
3. Guest Allowed
This is all implemented via an "include" so it should be extremely easy to implement / upgrade. In each file that you want to protect, you'll add a single line of code that includes the page management module. The included code will check the page configuration and check the user status (logged in / out, admin or not) and page status (disable or not) and react accordingly.
這支外掛也如時強力地管理訪客的權限! 跟上面的Admin Required的原理也是一樣^^
4. Page Counter
這個功能讓你可以在後台設定瀏覽權限時, 可以依照每個.php檔案被瀏覽的次數而作出決定。 當然, 這個基本上並不是什麼鬼功能啦....
不過這個功能唯一可以幫助你的是, 基於訪客或者惡意會員會不斷的重新整理你某個頁面, 惡意地增加你的流量, 你在後台可以參考這個Page Counter, 觀看和比較那一些.php出現離譜的總瀏覽次數...
如果你的站開了不久, 但是 memeberlist.php已經被瀏覽了幾千次, 你就可以者暫把這 memeberlist.php暫停瀏覽權限.......

這個是原作者提供的圖片: 你安裝這支外掛, 後台便會出現一個"瀏覽管理設定"
這裡你可以看到以上四個功能
1. Disable
2. Admin Required
3. Guest Allowed
4. Page Counter
原文翻譯, 及相關下載和更詳細的討論請參考:
http://www.phpbb.com/phpBB/viewtopic.php?t=290219
----------------------------------------------------------------------------------
中文化:*(有兩行並不能了解你的意思, 請原諒無法翻譯,將不斷的更新中文化的用字!有意見關於中文化請PM我, 這個我自己也沒法接受-.-!)
其中, "None"不打算翻成中文是覺得中文寫出來很古怪....
代碼: 選擇全部
#
#-----[ OPEN ]-------------------------------------
#
language/lang_english/lang_admin.php
#
#-----[ FIND ]-------------------------------------
#
//
// That's all Folks!
#
#-----[ BEFORE, ADD ]-------------------------------------
#
// BEGIN Page Permissions 1.0.0 (www.phpBBDoctor.com)
$lang['Add_new_page'] = '新增瀏覽頁面';
$lang['No_page_selected'] = '沒有頁面被選擇';
$lang['No_page_group'] = 'None';
$lang['Unknown_group_type'] = '不知明';
$lang['Page_permissions_admin_title'] = '檢視管理權限設定';
$lang['Page_permissions_element'] = '瀏覽頁面';
$lang['Page_ID'] = '瀏覽頁面 ID (系統指派)';
$lang['Page_name'] = '編號';
$lang['Page_function'] = '瀏覽頁面功能';
$lang['Guest_views'] = '訪客瀏覽';
$lang['Guest_views_pct'] = '百分比';
$lang['Guest_views_explain'] = '此瀏覽統計收集所有訪客瀏覽過的總頁面次數,系統管理員可以自行調整觀看次數。';
$lang['Member_views'] = '註冊會員瀏覽';
$lang['Member_views_pct'] = '百分比';
$lang['Member_views_explain'] = '此瀏覽統計收集所有註冊會員瀏覽過的總頁面次數,系統管理員可以自行調整觀看次數。';
$lang['Page_views'] = '檢視次數';
$lang['Page_views_pct'] = '百分比';
$lang['Total_page_views'] = '總瀏覽次數';
$lang['Page_permissions_explain'] = '此清單統計你指定的瀏覽頁面的總觀看次數。ID是系統自行指派。當註冊和訪客進入任何一個你指定的瀏覽頁面,系統就會自動更新統計數據。你可以利用此外掛功能去限制和禁止某一個瀏覽頁面,或者建立瀏覽權限等相關的功能。';
$lang['Disable_page'] = '要禁止嗎?';
$lang['Disable_page_explain'] = '此功能賦予你禁止個別瀏覽頁面,而不需要關閉整個論壇。所有系統管理階級人員仍然順利可以瀏覽,不過禁止其他會員和訪客進入此頁面。禁止時期可自行設定訊息提醒會員。';
$lang['Auth_level'] = '認證階級';
$lang['Page_parm_name'] = 'Parameter';
$lang['Page_parm_name_explain'] = 'Some pages have parameters based by GET or POST. If you want to check for a specific value, enter the parameter name to check here. An example might be "mode" for the profile page. You might want to set different permissions for "register" than you would for "viewprofile" or other values. Note that you do <b>not</b> have to define all possible parameter values, only those that you want to track or assign permissions to.';
$lang['Page_parm_value'] = 'Value (Required if Parameter is provided)';
$lang['Min_post_count'] = '最低總發表數';
$lang['Min_post_count_explain'] = '選擇"0"賦予某些瀏覽頁面的瀏覽權限必需以你所設定的最低總發表數。';
$lang['Max_post_count'] = '最高總發表數';
$lang['Max_post_count_explain'] = '選擇"0"表現你賦予某些瀏覽頁面的瀏覽權限必需以你所設定的最高總發表數。這個功能並不建議使用!';
$lang['Page_group'] = '群組認證';
$lang['Page_group_explain'] = '選擇個別或者多個群組賦予認證階級<b>Private</b>進入瀏覽頁面。';
$lang['Permission_public'] = '公開';
$lang['Permission_registered'] = '註冊會員';
$lang['Permission_private'] = '私人群組';
$lang['Permission_moderator'] = '版主管理員';
$lang['Permission_administrator'] = '系統管理員';
// Added when we included ability to enable / disable page view counts
$lang['Page_view_count_is'] = '目前瀏覽統計: ';
$lang['Count_views'] = '增加瀏覽統計: ';
$lang['Save_count_views'] = ' 儲存 ';
// Added when we included ability to mass enable / disable pages on page listing
$lang['Update_selected_pages'] = '更新選擇的頁面';
$lang['1_page_enabled'] = '目前有 1 個瀏覽頁面開放中';
$lang['1_page_disabled'] = '目前有 1 個瀏覽頁面禁止中';
$lang['X_pages_enabled'] = '目前有 %d 個瀏覽頁面開放中';
$lang['X_pages_disabled'] = '目前有 %d 個瀏覽頁面禁止中';
// General admin token strings used
// in all phpBBDoctor admin pages
$lang['Updated'] = ' 更新 ';
$lang['Inserted'] = ' 添加';
$lang['Deleted'] = ' 刪除 ';
$lang['Rebuild_cache'] = '重設快速緩衝貯存(cache)';
$lang['Cache_updated'] = ' 快速緩衝貯存(cache)更新 ';
$lang['Click_return_list'] = '請按 %s這裡%s 返回 %s 設定清單';
// END Page Permissions 1.0.0 (www.phpBBDoctor.com)
代碼: 選擇全部
#
#-----[ OPEN ]-------------------------------------
#
language/lang_english/lang_main.php
#
#-----[ FIND ]-------------------------------------
#
//
// That's all, Folks!
#
#-----[ BEFORE, ADD ]-------------------------------------
#
// BEGIN Page Permissions 1.0.0 (www.phpBBDoctor.com)
$lang['Page_disabled'] = '目前正在維護中, 暫時關閉瀏覽方便進度!';
$lang['Insufficient_privileges'] = '很抱歉!你並未獲授權檢視此頁!';
$lang['Post_count_too_low'] = '很抱歉!你的總發文數並未達到要求, 你無法檢視此頁!';
$lang['Post_count_too_high'] = '很抱歉!你的總發文數已經超出限制, 你無法檢視此頁!';
// END Page Permissions 1.0.0 (www.phpBBDoctor.com)