No unsafe-inline 1.2.1

Does No unsafe-inline work with WordPress 6.6.2 and PHP 8.1.12? A smoke test was performed on .

Summary

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

Memory usage: 158.69 KiB
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.6.2
PHP version8.1.12
MySQL version10.6.10
PHP memory limit512M
Plugin Info
Last updated
Active installs 100+
WordPress.org page https://wordpress.org/plugins/no-unsafe-inline/
Badges

WordPress compatibility badge PHP compatibility badge

Get badge code

Pages 9

Plugins ‹ Test site — WordPress

Page screenshot: Plugins ‹ Test site — WordPress
URL /wp-admin/plugins.php?plugin_status=all&paged=1&s
Requested URL /wp-admin/plugins.php?action=activate&plugin=no-unsafe-inline%2Fno-unsafe-inline.php&plugin_status=all&paged=1&s&_wpnonce=0103cc0eac
Aspect after-activation
HTTP status 200
Load time 0.444 s
Memory usage 3.66 MiB
JS errors None
Resource errors None

Settings → CSP settings

Page screenshot: Settings → CSP settings
URL /wp-admin/options-general.php?page=no-unsafe-inline
Aspect menu-item
HTTP status 200
Load time 0.359 s
Memory usage 3.65 MiB
JS errors None
Resource errors None

Settings → CSP settings → Base rules

Page screenshot: Settings → CSP settings → Base rules
URL /wp-admin/options-general.php?page=no-unsafe-inline&tab=base-rule
Aspect menu-item-tab
HTTP status 200
Load time 0.223 s
Memory usage 3.61 MiB
JS errors None
Resource errors None

Settings → CSP settings → External whitelist

Page screenshot: Settings → CSP settings → External whitelist
URL /wp-admin/options-general.php?page=no-unsafe-inline&tab=external
Aspect menu-item-tab
HTTP status 200
Load time 0.222 s
Memory usage 3.62 MiB
JS errors None
Resource errors None

Settings → CSP settings → Inline whitelist

Page screenshot: Settings → CSP settings → Inline whitelist
URL /wp-admin/options-general.php?page=no-unsafe-inline&tab=inline
Aspect menu-item-tab
HTTP status 200
Load time 0.231 s
Memory usage 3.62 MiB
JS errors None
Resource errors None

Settings → CSP settings → Events whitelist

Page screenshot: Settings → CSP settings → Events whitelist
URL /wp-admin/options-general.php?page=no-unsafe-inline&tab=events
Aspect menu-item-tab
HTTP status 200
Load time 0.230 s
Memory usage 3.62 MiB
JS errors None
Resource errors None

Settings → CSP settings → Settings

Page screenshot: Settings → CSP settings → Settings
URL /wp-admin/options-general.php?page=no-unsafe-inline&tab=settings
Aspect menu-item-tab
HTTP status 200
Load time 0.257 s
Memory usage 3.63 MiB
JS errors None
Resource errors None

Settings → CSP settings → Logs

Page screenshot: Settings → CSP settings → Logs
URL /wp-admin/options-general.php?page=no-unsafe-inline&tab=logs
Aspect menu-item-tab
HTTP status 200
Load time 0.224 s
Memory usage 3.62 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.188 s
Memory usage 3.46 MiB
JS errors None
Resource errors None

Benchmark

URL Load time Memory usage
Inactive Active Change Inactive Active Change
/wp-admin/index.php0.350 s0.300 s-0.050 s3.47 MiB3.63 MiB+ 161.52 KiB
/wp-admin/edit.php0.202 s0.198 s-0.004 s3.54 MiB3.69 MiB+ 160.55 KiB
/wp-admin/post-new.php0.739 s0.612 s-0.127 s5.75 MiB5.91 MiB+ 165.09 KiB
/wp-admin/upload.php0.619 s0.429 s-0.190 s3.49 MiB3.63 MiB+ 143.51 KiB
/wp-admin/options-writing.php0.206 s0.207 s+0.001 s3.41 MiB3.61 MiB+ 206.31 KiB
/wp-admin/media-new.php0.238 s0.223 s-0.015 s3.4 MiB3.61 MiB+ 219.7 KiB
/wp-admin/edit-tags.php?taxonomy=category0.190 s0.209 s+0.019 s3.47 MiB3.63 MiB+ 166.37 KiB
/wp-admin/post-new.php?post_type=page0.582 s0.588 s+0.006 s5.75 MiB5.9 MiB+ 160.67 KiB
/wp-admin/options-discussion.php0.217 s0.442 s+0.225 s3.41 MiB3.61 MiB+ 208 KiB
/wp-admin/edit-comments.php0.222 s0.247 s+0.025 s3.49 MiB3.63 MiB+ 143.5 KiB
/0.303 s0.203 s-0.100 s3.45 MiB3.46 MiB+ 10.43 KiB
Average 0.352 s0.333 s-0.019 s3.87 MiB4.03 MiB+ 158.69 KiB

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.

PHP
CSS
PO File
Language % Lines of code Comment lines Files
PHP53.5%9,5494,86052
CSS33.1%5,90228912
PO File8.3%1,4905961
JavaScript4.8%865745
JSON0.3%4801
Total 17,854 5,819 71

PHP Code Analysis | More results »

Lines of code 9,069
Total complexity 1,723
Median class complexity 21.0
Median method complexity 2.0
Most complex class No_Unsafe_Inline_Admin
Most complex function NUNIL\Nunil_Manipulate_DOM::manipulate_external_node()
Classes 35
Methods 407
Functions 7

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 5

Options wp_options 6

PHP Error Log 1 lines

[21-Sep-2024 07:50:00 UTC] PHP Warning:  copy(/wp-content/mu-plugins/no-unsafe-inline-output-buffering.php): Failed to open stream: Permission denied in /wp-content/plugins/no-unsafe-inline/src/Nunil_Manage_Muplugin.php on line 68
See also: All tests for this plugin, How to Hide the "CSP settings" Admin Menu