Title: OTP Content Protect
Author: Tim Ehling
Published: <strong>2025 年 7 月 10 日</strong>
Last modified: 2025 年 7 月 18 日

---

搜索插件

![](https://ps.w.org/otp-content-protect/assets/banner-772x250.png?rev=3325625)

**该插件尚未通过WordPress的最新3个主要版本进行测试**。 当与较新版本的WordPress一起
使用时，可能不再受到维护或支持，并且可能会存在兼容性问题。

![](https://ps.w.org/otp-content-protect/assets/icon-256x256.png?rev=3325625)

# OTP Content Protect

 作者：[Tim Ehling](https://profiles.wordpress.org/tehling/)

[下载](https://downloads.wordpress.org/plugin/otp-content-protect.1.3.5.zip)

 * [详情](https://cn.wordpress.org/plugins/otp-content-protect/#description)
 * [评价](https://cn.wordpress.org/plugins/otp-content-protect/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/otp-content-protect/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/otp-content-protect/#developers)

 [支持](https://wordpress.org/support/plugin/otp-content-protect/)

## 描述

As a WordPress owner who values both **security and a seamless user experience**,
you often face the challenge of protecting sensitive information. Most password 
solutions force your visitors to register for an account, granting them potential
access to your WordPress environment.

**This is where “OTP Content Protect” comes in, offering an innovative way to protect
your content with a One-Time Password (OTP).**

Our plugin was designed to give you full control over your content without opening
the doors to your WordPress backend for strangers. Easily and effectively protect
individual posts, pages, or even downloads. Your visitors don’t need an account 
and don’t have to register—they simply enter the one-time password you provide and
get instant access.

By not granting unnecessary backend access, you actively minimize the risk of hacker
or spam activities. “OTP Content Protect” is the perfect blend of simplicity, security,
and innovation, making it the ideal password protection for your WordPress site 
when you need to lock specific content without burdening users with registration.

#### Support & Feature Requests

We are constantly developing the plugin and welcome your feedback!

 * **For questions or issues,** please use the official [Support Forum on WordPress.org](https://wordpress.org/support/plugin/otp-content-protect/)
   or report a bug directly via our [Submit a Bug form](https://die-mainagentur.de/en/wordpress-plugin-otp-content-protect/#submitbug).
 * **Have an idea for a new feature?** Submit your feature request easily through
   our website: [Submit a Feature Request](https://die-mainagentur.de/en/wordpress-plugin-otp-content-protect/#featurerequest).

### Features

 * **Protection Without Registration:** The key advantage—visitors don’t need a 
   WordPress account.
 * **Flexible Content Protection:** Secure posts, pages, or any custom post type.
 * **Simple Password Generation:** Creates secure, alphanumeric OTPs (8–10 characters).
 * **Full Control:** Stores creation date, optional expiration date, and a timestamp
   of when it was used.
 * **Reusable Passwords:** A used OTP can easily be reset for reuse.
 * **Modern Admin Interface:** AJAX-powered content list with search and convenient
   post-type tabs.
 * **Clean Uninstall:** An uninstall script completely removes all plugin data from
   the database upon deletion if desired.
 * **Built for the World:** Fully internationalized (i18n) and ready for translation.

### Usage

 1. Go to the OTP Protect settings page.
 2. Select the content to protect and generate or enter an OTP.
 3. (Optional) Set an expiration date.
 4. Save the OTP and share it with the intended users.
 5. When a visitor accesses the protected content, they will see a simple input form
    for the password.
 6. Upon valid entry, the original content is displayed instantly.
 7. In the admin overview, you can easily reset or delete used OTPs.

## 屏幕截图

[⌊The settings page—a clear overview of all generated one-time passwords with key
actions like edit, delete, and reset.⌉⌊The settings page—a clear overview of all
generated one-time passwords with key actions like edit, delete, and reset.⌉[

The settings page—a clear overview of all generated one-time passwords with key 
actions like edit, delete, and reset.

[⌊The simple password input form a visitor sees on a protected page.⌉⌊The simple
password input form a visitor sees on a protected page.⌉[

The simple password input form a visitor sees on a protected page.

[[

## 安装

 1. Unzip and upload the `otp-content-protect` folder to your `/wp-content/plugins/`
    directory. Alternatively, find and install it directly via the “Add New” plugin
    screen.
 2. Activate the plugin through the ‘Plugins’ menu in WordPress.
 3. Navigate to Settings  OTP Protect to configure and generate OTPs.

## 常见问题

### Do users need to register to view the content?

No, and that is the plugin’s main advantage. A user only needs to enter the one-
time password you provide. No WordPress user account is required.

### How can I allow an OTP to be used more than once?

In the admin overview, you can edit any used OTP and reset it with a single click.
This clears the usage timestamp and makes the password immediately valid again.

### Is plugin data removed on uninstall?

Yes. When you delete the plugin from the WordPress admin area, the included `uninstall.
php` file ensures the associated database table (`<prefix>_otpcp_protect`) is cleanly
removed.

### Can multiple passwords be active for the same post?

Yes. You can create multiple different and simultaneously active OTPs for the same
piece of content. Each one will be validated correctly upon entry.

## 评价

![](https://secure.gravatar.com/avatar/e5f8b4b0f0fbdd862a887d2f6aa98a6409d754ee637370f00263b846a1b98a1a?
s=60&d=retro&r=g)

### 󠀁[Secure Pages, No Logins: Why OTP Content Protect is a Game-Changer](https://wordpress.org/support/topic/secure-pages-no-logins-why-otp-content-protect-is-a-game-changer/)󠁿

 [schco](https://profiles.wordpress.org/schco/) 2025 年 7 月 12 日 1 回复

As a WordPress owner who’s serious about both security and user experience, I’ve
explored countless plugins to protect my content. Most OTP (One-Time Password) solutions
I evaluated work only at the login or user role level. While that’s fine for managing
site users, it’s not ideal if you simply want to secure specific content without
opening the doors to your entire WordPress backend. That’s where the OTP Content
Protect WordPress Plugin truly shines. I think this plugin is innovative because
it operates on the page/post level without requiring users to register. For me, 
that’s a game-changer. I don’t want casual visitors or customers to have access 
to my WordPress infrastructure at all—it’s not just a matter of convenience but 
a critical security measure to limit potential hacker or spammer activity. With 
this plugin, I can lock down sensitive pages, downloadable resources, or exclusive
content behind a one-time password barrier, and never expose my admin or user management
system to strangers. Overall, the OTP Content Protect WordPress Plugin fills a unique
niche. It lets me confidently protect premium content without entangling users in
account creation or risking unwanted access to my WordPress environment. It’s the
perfect blend of simplicity, security, and innovation. Highly recommended for any
site owner who wants to keep their WordPress infrastructure locked down while delivering
secure, user-friendly content access.

 [ 阅读所有1条评价 ](https://wordpress.org/support/plugin/otp-content-protect/reviews/)

## 贡献者及开发者

「OTP Content Protect」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ Tim Ehling ](https://profiles.wordpress.org/tehling/)

[帮助将「OTP Content Protect」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/otp-content-protect)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/otp-content-protect/)，
查看[SVN仓库](https://plugins.svn.wordpress.org/otp-content-protect/)，或通过[RSS](https://plugins.trac.wordpress.org/log/otp-content-protect/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/otp-content-protect/)。

## 更新日志

#### 1.3.5

 * **Enhancement:** Implemented a new protection method using the `template_redirect`
   hook to provide proper compatibility for WooCommerce Products.
 * **Enhancement:** Added a “View” link to the row actions in the admin list to 
   quickly open the protected content.

#### 1.3.4

 * **Enhancement:** Replaced the password list with a professional, sortable, and
   searchable table (WP_List_Table).
 * **Enhancement:** Restructured the admin page to match WordPress standards (separate
   Add/Edit view), which also fixes the placement of admin notices.
 * **Tweak:** Updated the styling of filter buttons to match the modern WordPress
   UI.

#### 1.3.3

 * **Fix:** Corrected a bug where only the first created OTP for a page was accepted.
   Now, multiple different OTPs can be active for the same content simultaneously,
   and each will be validated correctly.

#### 1.3.2

 * **Fix:** Addressed final `WordPress.DB.PreparedSQL.NotPrepared` false-positive
   errors by adding specific `phpcs:ignore` comments to pass the “Plugin Check” 
   tool cleanly.

#### 1.3.1

 * **Fix:** Resolved several warnings from the “Plugin Check” tool related to direct
   database queries and input validation.

#### 1.3.0

 * **Security:** Major refactoring to meet official WordPress.org requirements. 
   All functions, classes, hooks, and the database table now use a unique `otpcp_`
   prefix to prevent conflicts.
 * **Security:** Standardized and improved all nonce checks for better security.
 * **Fix:** Corrected various bugs in the admin area, including broken edit links
   and script loading issues that arose during the refactoring.

## 额外信息

 *  版本 **1.3.5**
 *  最后更新：**1 年前**
 *  活跃安装数量 **40+**
 *  WordPress 版本 ** 6.0 或更高版本 **
 *  已测试的最高版本为 **6.8.12**
 *  PHP 版本 ** 7.0 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/otp-content-protect/)
 * 标签
 * [content locker](https://cn.wordpress.org/plugins/tags/content-locker/)[content protect](https://cn.wordpress.org/plugins/tags/content-protect/)
   [otp](https://cn.wordpress.org/plugins/tags/otp/)[Password Protect](https://cn.wordpress.org/plugins/tags/password-protect/)
 *  [高级视图](https://cn.wordpress.org/plugins/otp-content-protect/advanced/)

## 评级

 5 星（最高 5 星）。

 *  [  1 条 5 星评价     ](https://wordpress.org/support/plugin/otp-content-protect/reviews/?filter=5)
 *  [  0 条 4 星评价     ](https://wordpress.org/support/plugin/otp-content-protect/reviews/?filter=4)
 *  [  0 条 3 星评价     ](https://wordpress.org/support/plugin/otp-content-protect/reviews/?filter=3)
 *  [  0 条 2 星评价     ](https://wordpress.org/support/plugin/otp-content-protect/reviews/?filter=2)
 *  [  0 条 1 星评价     ](https://wordpress.org/support/plugin/otp-content-protect/reviews/?filter=1)

[您的评价](https://wordpress.org/support/plugin/otp-content-protect/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/otp-content-protect/reviews/)

## 贡献者

 *   [ Tim Ehling ](https://profiles.wordpress.org/tehling/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/otp-content-protect/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](https://die-mainagentur.de)