Restrict Content 3.1.6

Does Restrict Content work with WordPress 6.1.1 and PHP 7.4.8? A smoke test was performed on .

Summary

Errors
1Database errors
1JavaScript exceptions
All test pages loaded successfully
No resource errors
Performance

Memory usage: 1.36 MiB
The average PHP memory usage increased by this amount after activating by the plugin.

Page speed impact: insignificant.
The plugin didn't make the site noticeably slower.

Environment
WordPress version6.1.1
PHP version7.4.8
MySQL version8.0.21
PHP memory limit256M
Plugin Info
Last updated
Active installs 10,000+
WordPress.org page https://wordpress.org/plugins/restrict-content/
Badges

WordPress compatibility badge PHP compatibility badge

Get badge code

Pages 7

‹ Test site — WordPress

Page screenshot: ‹ Test site — WordPress
URL /wp-admin/admin.php?page=restrict-content-welcome
Requested URL /wp-admin/plugins.php?action=activate&plugin=restrict-content%2Frestrictcontent.php&plugin_status=all&paged=1&s&_wpnonce=13e200975d
Aspect after-activation
HTTP status 200
Load time 1.959 s
Memory usage 4.87 MiB
JS errors
[
    {
        "message": "TypeError: Cannot read properties of undefined (reading 'hasAttribute')\n    at determineDelay (/wp-content/plugins/restrict-content/legacy/includes/assets/js/rc-admin.js?ver=3.5.22:230:36)\n    at /wp-content/plugins/restrict-content/legacy/includes/assets/js/rc-admin.js?ver=3.5.22:12:21\n    at HTMLDocument.<anonymous> (/wp-content/plugins/restrict-content/legacy/includes/assets/js/rc-admin.js?ver=3.5.22:262:6)\n    at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.1.1:2:30038)\n    at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.1.1:2:30340)",
        "trace": null,
        "code": null
    }
]
Resource errors None

Posts → Restrict Access

Page screenshot: Posts → Restrict Access
URL /wp-admin/edit.php?page=rcp-restrict-post-type
Aspect menu-item
HTTP status 200
Load time 0.206 s
Memory usage 4.83 MiB
JS errors None
Resource errors None

Pages → Restrict Access

Page screenshot: Pages → Restrict Access
URL /wp-admin/edit.php?post_type=page&page=rcp-restrict-post-type-page
Aspect menu-item
HTTP status 200
Load time 0.191 s
Memory usage 4.77 MiB
JS errors None
Resource errors None

Restrict

Page screenshot: Restrict
URL /wp-admin/admin.php?page=rcp-members
Aspect menu-item
HTTP status 200
Load time 0.314 s
Memory usage 5.17 MiB
JS errors None
Resource errors None

Test site – Just another WordPress site

Page screenshot: Test site – Just another WordPress site
URL /
Aspect front-page
HTTP status 200
Load time 0.280 s
Memory usage 4.57 MiB
JS errors None
Resource errors None

Add New Post ‹ Test site — WordPress

Page screenshot: Add New Post ‹ Test site — WordPress
URL /wp-admin/post-new.php
Aspect new-meta-boxes
HTTP status 200
Load time 0.935 s
Memory usage 6.89 MiB
JS errors None
Resource errors None

Add New Page ‹ Test site — WordPress

Page screenshot: Add New Page ‹ Test site — WordPress
URL /wp-admin/post-new.php?post_type=page
Aspect new-meta-boxes
HTTP status 200
Load time 0.691 s
Memory usage 6.88 MiB
JS errors None
Resource errors None

Benchmark

URL Load time Memory usage
Inactive Active Change Inactive Active Change
/wp-admin/index.php0.261 s0.271 s+0.010 s3.54 MiB4.86 MiB+ 1.32 MiB
/wp-admin/edit.php0.177 s0.212 s+0.035 s3.57 MiB5.04 MiB+ 1.47 MiB
/wp-admin/post-new.php0.834 s0.989 s+0.155 s5.46 MiB6.89 MiB+ 1.43 MiB
/wp-admin/upload.php0.685 s0.495 s-0.190 s3.41 MiB4.8 MiB+ 1.39 MiB
/wp-admin/options-writing.php0.181 s0.171 s-0.010 s3.4 MiB4.78 MiB+ 1.37 MiB
/wp-admin/media-new.php0.277 s0.213 s-0.064 s3.39 MiB4.76 MiB+ 1.37 MiB
/wp-admin/edit-tags.php?taxonomy=category0.189 s0.210 s+0.021 s3.48 MiB4.81 MiB+ 1.34 MiB
/wp-admin/post-new.php?post_type=page0.607 s0.683 s+0.076 s5.46 MiB6.88 MiB+ 1.42 MiB
/wp-admin/options-discussion.php0.220 s0.243 s+0.023 s3.38 MiB4.78 MiB+ 1.39 MiB
/wp-admin/edit-comments.php0.217 s0.221 s+0.004 s3.48 MiB4.81 MiB+ 1.33 MiB
/0.275 s0.241 s-0.034 s3.44 MiB4.56 MiB+ 1.13 MiB
Average 0.357 s0.359 s+0.002 s3.82 MiB5.18 MiB+ 1.36 MiB

Code Statistics

Note: Third-party libraries and minified JS/CSS files are excluded from these statistics where possible, so the numbers you see here may be lower than those reported by other tools.

PO File
PHP
Language % Lines of code Comment lines Files
PO File50.4%82,88446,77417
PHP44.1%72,55347,845527
CSS2.2%3,68815023
JavaScript2.1%3,49999822
Markdown0.7%1,20605
SVG0.2%252039
JSON0.1%21905
Sass0.0%5402
XML0.0%3101
make0.0%2701
Total 164,413 95,767 642

PHP Code Analysis | More results »

Lines of code 59,437
Total complexity 13,780
Median class complexity 4.0
Median method complexity 2.0
Most complex class Freemius
Most complex function rcp_tools_system_info_report()
Classes 326
Methods 2,671
Functions 791

Additions

Things that the plugin adds to the site. This section is not intended to be comprehensive. The test tool only looks for a few specific types of added content.

Database Tables 11

Options wp_options 20

User Metadata wp_usermeta 1

Custom Post Types 1

ID Name
wp_logLogs

Meta Boxes

{
    "post": {
        "rcp_meta_box": {
            "title": "Restrict this content",
            "context": "normal"
        }
    },
    "page": {
        "rcp_meta_box": {
            "title": "Restrict this content",
            "context": "normal"
        }
    }
}

Capabilities 11

PHP Error Log 7 lines

[16-Nov-2022 10:35:39 UTC] WordPress database error You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'CONTAINS '[restrict]' OR 
                          post_content CONTAINS '[not_' at line 2 for query SELECT * FROM wp_posts WHERE 
                          post_content CONTAINS '[restrict]' OR 
                          post_content CONTAINS '[not_logged_in]' OR
                          post_content CONTAINS '[login_form]' OR
                          post_content CONTAINS '[register_form]' OR
                          LIMIT 1 made by activate_plugin, plugin_sandbox_scrape, include_once('/plugins/restrict-content/restrictcontent.php'), RC_Requirements_Check->__construct, RC_Requirements_Check->load, RC_Requirements_Check->restrict_content_check_posts_for_shortcode
See also: All tests for this plugin, How to Hide Restrict Content Admin Menus and Meta Boxes