| 开发者 | salmamohamed25 |
|---|---|
| 更新时间 | 2026年9月18日 04:45 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 7.1 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
[tutor_login] and [tutor_student_registration_form] shortcodes, so validation, password handling and account creation all stay in Tutor where they belong. The redirect uses Tutor's own supported redirect_to field.
Access is enforced on the server, so the restriction cannot be bypassed by opening the lesson URL directly or by disabling JavaScript.
Privacy
This plugin makes no external requests, loads no remote assets, and collects, stores or transmits no personal data. It reads Tutor LMS course and lesson data already in your database, and stores a single settings row. A short-lived cookie is set in the visitor's browser only to remember which lesson they were trying to reach, so they can be returned to it after signing in.
Source code
Development happens at https://github.com/salma25128/sbytes-restrict-preview-for-tutor-lms — issues and pull requests are welcome. The plugin ships as plain, unminified PHP, CSS and JavaScript with no build step, so the distributed code is the source code.
Trademarks
Tutor LMS is a trademark of Themeum. This plugin is an independent, third-party extension and is not affiliated with, endorsed by, or sponsored by Themeum.
/wp-content/plugins/, or install it from the Plugins screen.No. It only affects lessons that are marked as free previews in Tutor LMS. Every other lesson keeps Tutor's normal enrolment gating, untouched.
No. The content is replaced on the server before the page is sent, so a direct URL, a disabled-JavaScript browser or a crawler all get the same prompt.
WordPress registration is switched off. Turn on Anyone can register under Settings → General. The tab is hidden rather than shown as a dead end, because Tutor's registration handler refuses to create accounts while that setting is off.
Badges are matched to real preview lessons by their URL, and they need a link to attach to. Themes that render the curriculum with heavily customised markup may not expose one. The plugin never guesses from the rendered text, because many courses never display the word "Free" at all.
The server-side gate works everywhere. If your curriculum is rendered somewhere unusual and the assets do not load, use the rptl_load_assets filter to force them on.
Yes, with the rptl_user_may_view_preview filter. It receives a boolean and lets you widen or narrow access.