內容簡介
描述:此外掛可以要求訪客每次訪問受密碼保護的頁面時輸入密碼。它還可以防止在公共電腦上輸入密碼後訪問該頁面。預設情況下,WordPress 受密碼保護的頁面會持續 10 天的會話。原本我是因為客戶不希望在關閉瀏覽器後仍可訪問受密碼保護的頁面而想到這個想法的。雖然您可以將代碼添加到主題中的 function.php 中,但當更新主題時,代碼可能會被覆蓋。使用此外掛可避免更新 function.php 文件的需要。
一旦你將它上傳到 WordPress 安裝中,只需登錄 WordPress 後台並啟用外掛程式。啟用後,您無需再做其他操作。您可以通過在輸入密碼後刷新頁面或關閉瀏覽器來測試頁面。再次訪問該頁面時,它將強制您輸入密碼。
請注意:如果您使用緩存外掛程式,可能會導致該外掛程式無法正常工作。請在緩存外掛程式中將您設置密碼保護的頁面加入白名單。
您可以下載並解壓縮此外掛程式,然後將其上傳到 /plugin 目錄。一旦上傳到您的 Web 主機,請登錄 WordPress 後台並啟用外掛程式。啟用後,您無需再做其他操作。
外掛標籤
開發者團隊
② 後台搜尋「Expire Password Protected Pages」→ 直接安裝(推薦)
原文外掛簡介
Description: This plugin will require visitors to type in the password each time they are visiting a password protected page. This also will prevent the page from being accessible if someone types in the password on a public computer. By default WordPress password protected pages sessions will last 10 days. Originally came up with this idea when a client did not want a password protected pages accessible after the browser was closed. While you could add the code to your function.php within your theme I did not want the code to get overwritten when doing a theme update. Using this plugin avoids the need for updating the function.php file.
Once you have it uploaded to your WordPress install. Simply login to your WordPress backend and activate the plugin. After it’s activated you no longer need to do anything. You can test the page by refreshing the page after typing the password or closing your browser. Once you visit the page again it will force you to type in the password.
Please note: If you use a cache plugin it may cause the plugin to not work correctly. Please whitelist the page you’re password protecting within your cache plugin.
You can use this plugin by downloading and unzippping it to the /plugin directory. Once you have it uploaded to your web host login to your WordPress backend and activate the plugin. After it’s activated you no longer need to do anything.
