| 1 |
=== Content Control - The Ultimate Content Restriction Plugin! Restrict Content, Create Conditional Blocks & More === |
| 2 |
Contributors: codeatlantic, danieliser |
| 3 |
Author URI: https://code-atlantic.com/?utm_campaign=upgrade-to-pro&utm_source=plugins-page&utm_medium=plugin-ui&utm_content=action-links-upgrade-text |
| 4 |
Plugin URI: https://contentcontrolplugin.com/?utm_campaign=plugin-info&utm_source=readme-header&utm_medium=plugin-ui&utm_content=author-uri |
| 5 |
Donate link: https://code-atlantic.com/donate/?utm_campaign=donations&utm_source=readme-header&utm_medium=plugin-ui&utm_content=donate-link |
| 6 |
Tags: access control, content, content restriction, permission, private, restrict, restrict access, restriction, user, visibility, widget, block visibility, user access, coming soon, maintenance mode, access manager, paywall |
| 7 |
Requires at least: 5.6 |
| 8 |
Tested up to: 6.4 |
| 9 |
Stable tag: 2.0.12 |
| 10 |
Requires PHP: 5.6 |
| 11 |
License: GPLv3 (or later) |
| 12 |
|
| 13 |
Restrict content based on login status, user roles, device type & more. Monetize your content with a paywall or members-only content. |
| 14 |
|
| 15 |
== Description == |
| 16 |
|
| 17 |
Content Control is a transformative plugin, allowing you to fine-tune every aspect of your WordPress website's content. Decide who gets to see what, where, and when - be it pages, posts, widgets, or individual block visibility using our handy shortcode. Your content, your rules, executed perfectly! |
| 18 |
|
| 19 |
Content Control is intuitive and powerful, designed for all users—whether logged in, holding specific roles, or even guests. Need top-tier content restriction or a dependable access manager for your site? Look no further. We've expanded our controls to include Gutenberg and Full Site Editor, giving you unmatched command. |
| 20 |
|
| 21 |
= Key Features = |
| 22 |
|
| 23 |
Discover what Content Control brings to your table: |
| 24 |
|
| 25 |
- Full control over your site's content, restrict user access with ease!. |
| 26 |
- Set up a seamless paywall for your content, providing teasers for users and prompting them to purchase access. |
| 27 |
- Per block controls for Gutenberg and Full Site Editor, including user roles, device type, and more. |
| 28 |
- Responsive block controls with customizable breakpoints. |
| 29 |
- Control block visibility by user status, roles, device type & more. |
| 30 |
- Restrict access to pages, posts, widgets, and individual blocks based on user status, roles, device type & more. |
| 31 |
- Offer membership tools for crafting membership access and members-only content. |
| 32 |
- Provide responsive block designs that adapt to varying device sizes. |
| 33 |
- Lockdown content selectively for improved user experiences. |
| 34 |
- Implement role-based redirections to guide users effectively. |
| 35 |
- Unlock the power of subscription content and monetization strategies. |
| 36 |
- Safeguard specific categories, tags, custom post types, and custom taxonomies. |
| 37 |
- Manage access to [media attachment pages](https://www.hongkiat.com/blog/wordpress-attachment-pages/) for logged in/out users or specific user roles. |
| 38 |
- Display a custom message to users who do not have permission to view the content. |
| 39 |
- Display specific content on a page or post to logged in users only, specific user roles, or logged out users. |
| 40 |
- Redirect users without access permission to a login page, website homepage, or a custom URL. |
| 41 |
- Highlight subscriber-only content for premium users. |
| 42 |
- Use the `[content_control]` shortcode to protect content inline and cater to subscriber preferences. |
| 43 |
- Control widget visibility by selecting the user type that can view each widget. |
| 44 |
- Conditionally show coming soon or maintenance mode pages based on various rules. |
| 45 |
|
| 46 |
[Content Control Documentation](https://contentcontrolplugin.com/docs/?utm_campaign=plugin-info&utm_source=readme-description&utm_medium=wordpress&utm_content=documentation-link) |
| 47 |
|
| 48 |
= Pro Features = |
| 49 |
|
| 50 |
Coming soon: Content Control Pro, with advanced features like: |
| 51 |
|
| 52 |
- Content Teasers for Paywalls, giving your users a sneak peek, leaving them wanting more. |
| 53 |
- Optimize your WooCommerce & Easy Digital Downloads (EDD) experiences with advanced rules. |
| 54 |
- Schedule blocks, controlling content visibility timings using customizable scheduling rules. |
| 55 |
- Dive deeper with advanced block rules and a boolean editor. |
| 56 |
- Customize login, registration & recovery page urls. Custom login urls give a more personalized user experience. |
| 57 |
|
| 58 |
**Note**: Content Control handles media access via content on media attachment pages but won't restrict direct server-level access to media files. |
| 59 |
|
| 60 |
= Passionately Crafted by Code Atlantic = |
| 61 |
|
| 62 |
At [Code Atlantic][codeatlantic], we're passionate about crafting tools that empower your digital journey. Content Control is a testament to our commitment to quality. |
| 63 |
|
| 64 |
Dive into some of our renowned plugins: |
| 65 |
|
| 66 |
- **[Popup Maker][popupmaker]** - The #1 Popup & Marketing Plugin for WordPress |
| 67 |
- **[User Menus][usermenus]** - Innovatively Show, Hide & Customize Menu Items |
| 68 |
|
| 69 |
[codeatlantic]: https://code-atlantic.com "Code Atlantic - High Quality WordPress Plugins" |
| 70 |
[popupmaker]: https://wppopupmaker.com "#1 Popup & Marketing Plugin for WordPress" |
| 71 |
[usermenus]: https://wordpress.org/plugins/user-menus/ "Show, Hide & Customize Menu Items For Different Users" |
| 72 |
|
| 73 |
== Installation == |
| 74 |
|
| 75 |
- Install Content Control either via the WordPress.org plugin repository or by uploading the files to your server. |
| 76 |
- Activate Content Control. |
| 77 |
|
| 78 |
If you need help getting started with Content Control please see [FAQs][faq page] which explains how to use the plugin. |
| 79 |
|
| 80 |
[faq page]: https://wordpress.org/plugins/content-control/faq/ "Content Control FAQ" |
| 81 |
|
| 82 |
== Frequently Asked Questions == |
| 83 |
|
| 84 |
= Where can I get support? = |
| 85 |
|
| 86 |
If you get stuck, you can ask for help in the [Content Control Plugin Forum](http://wordpress.org/support/plugin/content-control). |
| 87 |
|
| 88 |
= Where can I report bugs or contribute to the project? = |
| 89 |
|
| 90 |
Bugs can be reported either in our support forum or we are happy to accept PRs on the [Content Control GitHub repo](https://github.com/code-atlantic/content-control/issues). |
| 91 |
|
| 92 |
== Screenshots == |
| 93 |
|
| 94 |
1. Restrict access to individual blocks. |
| 95 |
2. Create unlimited restriction sets. |
| 96 |
3. Choose who can see the restricted content. |
| 97 |
4. Display a message in place of restricted content. |
| 98 |
5. Redirect users to log in or to another page if they access restricted content. |
| 99 |
6. Choose any content you can think of to protect. |
| 100 |
7. Use shortcodes to protect content inline. |
| 101 |
8. Restrict widgets as well. |
| 102 |
|
| 103 |
== Changelog == |
| 104 |
|
| 105 |
= v2.0.12 - 10/26/2023 = |
| 106 |
|
| 107 |
- Fix: Prevent extra 301 redirect due to missing trailing slash on some URLs. |
| 108 |
- Fix: Issue with Custom Message replacement not always working on pages built with Elementor. |
| 109 |
|
| 110 |
= v2.0.11 - 10/04/2023 = |
| 111 |
|
| 112 |
- Improvement: Query Monitor integration to show which restrictions are active on a page. |
| 113 |
- Shows global settings that may be affecting the page. |
| 114 |
- Shows which restrictions are active on the page. |
| 115 |
- Shows which posts are being filtered out of queries and by which restriction. |
| 116 |
- Tweak: Ensure upgrade stream doesn't send headers if they were already sent. |
| 117 |
- Tweak: Make second arg on get_the_excerpt filter optional to prevent errors with some plugins. |
| 118 |
- Fix: Bug when using `content_control/check_all_restrictions` filter that caused rules to not compare properly. |
| 119 |
|
| 120 |
= v2.0.10 - 10/01/2023 = |
| 121 |
|
| 122 |
- Improvement: If no v1 global restrictions existed, skip the migration step entirely. |
| 123 |
- Improvement: Default to late init of post query filtering until after plugins_loaded should be finished. This should prevent help prevent random errors due to restrictions being checked before plugins have had a chance to register their post types, and thus restrictions won't properly match those post type rules. |
| 124 |
- Improvement: Add check to prevent restriction checks for **WP CLI** requests. |
| 125 |
- Improvement: Add notice to indicate is when waiting for post/page search results in the restriction editor fields. |
| 126 |
- Tweak: Fix issue in build that caused autoloader to not fully use optimized classmap, should result in improved performance. |
| 127 |
- Fix: Ensure `$wp_rewrite` is available before calling `is_rest()` -> `get_rest_url()`. This should prevent errors when using the plugin with **WP CLI** and when plugins make `WP_Query` calls during `plugins_loaded`. |
| 128 |
- Fix: Don't attempt to initialize side query filtering until after_theme_setup hook. This should prevent errors when plugins make `WP_Query` calls during `plugins_loaded`, and allow further delaying initialization if needed from themes `functions.php` file. |
| 129 |
- Fix: Backward compatibility issue with WP versions <6.2 that made settings page not render. |
| 130 |
- Fix: Bug where Block Controls didn't work on WooCommerce pages. This was filtering `pre_render_block` but not returning a value. Now we run our check after theirs to ensure that bug has no effect on our plugin. [Report](https://github.com/woocommerce/woocommerce-blocks/issues/11077) |
| 131 |
|
| 132 |
= v2.0.9 - 09/24/2023 = |
| 133 |
|
| 134 |
- Improvement: Better handling of restriction titles & content. Admins with priv can insert any content into the restriction messages. |
| 135 |
- Improvement: Added new filter `content_control/query_filter_init_hook` to allow delaying query filtering for compatibility with plugins that make custom queries before `template_redirect` action. |
| 136 |
|
| 137 |
``` |
| 138 |
add_filter( 'content_control/query_filter_init_hook', function () { |
| 139 |
return 'init'; // Try setup_theme, after_theme_setup, init or wp_loaded |
| 140 |
} ); |
| 141 |
``` |
| 142 |
|
| 143 |
- Tweak: Ensure our restriction checks work within a nested post loop. |
| 144 |
- Tweak: Change how restriction title & descriptions were sent/received over Rest API. |
| 145 |
- Fix: Bug that caused some shortcodes to not render properly. |
| 146 |
- Fix: Bug where override message wasn't used. |
| 147 |
- Fix: Bug where Elementor Post loop would render incorrectly when using ACF fields in the loop template. |
| 148 |
|
| 149 |
= v2.0.8 - 09/22/2023 = |
| 150 |
|
| 151 |
- Tweak: Ignore many Elementor queries from being restricted. |
| 152 |
- Fix: Error when required upgrade was marked as complete. |
| 153 |
- Fix: Bug that caused secondary queries to be handled like main queries. |
| 154 |
|
| 155 |
= v2.0.7 - 09/21/2023 = |
| 156 |
|
| 157 |
- Tweak: Only log each unique plugin debug notice once to prevent filling log files quickly. |
| 158 |
- Tweak: Replace usage of `wp_upload_dir` with `wp_get_upload_dir` which is more performant. |
| 159 |
- Fix: Error in upgrades when no data is found to migrate. |
| 160 |
- Fix: Error when function is called early & global $wp_query is not yet available. |
| 161 |
- Fix: Conditional check that could always return false. |
| 162 |
- Developer: Implemented PHP Static Analysis to catch more bugs before they happen. Currently clean on lvl 6. |
| 163 |
|
| 164 |
= v2.0.6 - 09/19/2023 = |
| 165 |
|
| 166 |
- Improvement: Added data backup step to upgrade process that stores json export in the media library. |
| 167 |
- Improvement: Better error handling in the data upgrade process. |
| 168 |
- Fix: Fix bug in data upgrade process that caused it to never finish. |
| 169 |
- Fix: Possible error when no restriction match found in some custom` queries. |
| 170 |
|
| 171 |
= v2.0.5 - 09/18/2023 = |
| 172 |
|
| 173 |
- Fix: Fix errors on some sites with custom conditions due to registering all rules too early. |
| 174 |
|
| 175 |
= v2.0.4 - 09/18/2023 = |
| 176 |
|
| 177 |
- Fix: Error when WP Query vars include anonymous function closures. |
| 178 |
|
| 179 |
= v2.0.3 - 09/18/2023 = |
| 180 |
|
| 181 |
- Fix: Log errors instead of throwing exceptions to prevent uncaught exceptions turning into fatal errors. |
| 182 |
|
| 183 |
= v2.0.2 - 09/18/2023 = |
| 184 |
|
| 185 |
- Fix: Fatal error from error logger on systems without write access. |
| 186 |
|
| 187 |
= v2.0.1 - 09/17/2023 = |
| 188 |
|
| 189 |
- Fix: Fatal error from unregistered or unknown rule types from 3rd party plugins/themes or custom code. Now they are logged in plugin settings page. |
| 190 |
|
| 191 |
= v2.0.0 - 09/17/2023 = |
| 192 |
|
| 193 |
- Feature: Restrict individual blocks in the Gutenberg editor. |
| 194 |
- Feature: Restrict individual blocks in the Full Site Editor. |
| 195 |
- Feature: Use a custom page template for restricted content. |
| 196 |
- Feature: Restrict blocks by device type with customizable breakpoints. |
| 197 |
- Feature: Restrict blocks by user status & role. |
| 198 |
- Feature: Global restrictions now offer more control over how restricted content is handled. |
| 199 |
- Choose to redirect or replace content with a custom page. |
| 200 |
- Filter or hide posts in archives or custom loops. |
| 201 |
- Secondary controls for posts if found in an archive. |
| 202 |
- Improvement: Match or exclude specific roles. |
| 203 |
- Improvement: Updated interface with intuitive and responsive controls. |
| 204 |
- Improvement: Boolean editor improvements. |
| 205 |
- Improvement: Control who can modify plugin settings. |
| 206 |
- Improvement: Upgraded tooling & Code quality improvements. |
| 207 |
|
| 208 |
= v1.1.10 - 12/28/2022 = |
| 209 |
|
| 210 |
- Security: Fix unescaped output for CSS classname in the [contentcontrol] shortcode allowing users with the ability to edit posts to inject code into the page. |
| 211 |
|
| 212 |
= v1.1.9 - 09/30/2021 = |
| 213 |
|
| 214 |
- Fix: Error when using Gutenberg Preview. |
| 215 |
|
| 216 |
= v1.1.8 - 07/17/2021 = |
| 217 |
|
| 218 |
- Fix: Error when Elementor instance preview proptery was null. |
| 219 |
|
| 220 |
= v1.1.7 - 07/17/2021 = |
| 221 |
|
| 222 |
- Fix: Prevent warning if widget settings don't exist in options table. |
| 223 |
- Fix: Arbitrary limit of 10 on current items listed in Restriction Editor due to WP query default args. |
| 224 |
- Fix: Prevent restrictions from activating when using the Elementor page builder. |
| 225 |
|
| 226 |
= v1.1.6 - 03/21/2021 = |
| 227 |
|
| 228 |
- Fix: Nonce validation was preventing 3rd party plugin from saving widget settings when it failed. Thanks @jacobmischka |
| 229 |
- Fix: Prevent corrupted options from preventing saving of settings. |
| 230 |
|
| 231 |
= v1.1.5 - 02/22/2021 = |
| 232 |
|
| 233 |
- Fix: Issue where roles with `-` would not save when checked. |
| 234 |
|
| 235 |
= v1.1.4 - 03/24/2020 = |
| 236 |
|
| 237 |
- Improvement: Added gettext handling for several strings that were not translatable. |
| 238 |
- Tweak: Process shortcodes in default denial message contents. |
| 239 |
- Tweak: Various improvements in form reliability & user experience. |
| 240 |
- Fix: Issues with ajax search fields not retaining their values after save. |
| 241 |
- Fix: Issue where only would show 10 pages. |
| 242 |
- Fix: PHP 7.4 compatibility fixes. |
| 243 |
|
| 244 |
= v1.1.3 - 12/03/2019 = |
| 245 |
|
| 246 |
- Fix: Custom post type conditions were not always registered. |
| 247 |
|
| 248 |
= v1.1.2 - 11/10/2019 = |
| 249 |
|
| 250 |
- Tweak: Remove erroneous console.log messages in admin. |
| 251 |
- Fix: Fatal error when empty shortcode used. |
| 252 |
|
| 253 |
= v1.1.1 - 10/15/2019 = |
| 254 |
|
| 255 |
- Fix: Bugs where variables were not always the expected type. |
| 256 |
|
| 257 |
= v1.1.0 = |
| 258 |
|
| 259 |
- Improvement: Added default denial message to shortcode. |
| 260 |
- Improvement: Render nested shortcodes in the [content_control] shortcode. |
| 261 |
- Fix: Bug where multiple roles checked together in restriction editor. |
| 262 |
|
| 263 |
= v1.0.3 = |
| 264 |
|
| 265 |
- Fix: Minor notice on activation. |
| 266 |
|
| 267 |
= v1.0.2 = |
| 268 |
|
| 269 |
- Fix: Call to undefined function. |
| 270 |
|
| 271 |
= v1.0.1 = |
| 272 |
|
| 273 |
- Fix: Non static method called statically |
| 274 |
- Fix: Bug when using invalid variable type. |
| 275 |
|
| 276 |
= v1.0.0 = |
| 277 |
|
| 278 |
- Initial Release |
| 279 |
|