mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
Introduce DISALLOW_UNFILTERED_HTML
git-svn-id: http://svn.automattic.com/wordpress/trunk@14244 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
ebc2200460
commit
ffd9a036cd
@ -1018,6 +1018,12 @@ function map_meta_cap( $cap, $user_id ) {
|
||||
}
|
||||
// Fall through if not DISALLOW_FILE_MODS.
|
||||
case 'unfiltered_html':
|
||||
// Disallow unfiltered_html for all users, even admins and super admins.
|
||||
if ( defined('DISALLOW_UNFILTERED_HTML') && DISALLOW_UNFILTERED_HTML ) {
|
||||
$caps[] = 'do_not_allow';
|
||||
break;
|
||||
}
|
||||
// Fall through if not DISALLOW_UNFILTERED_HTML
|
||||
case 'delete_user':
|
||||
case 'delete_users':
|
||||
// If multisite these caps are allowed only for super admins.
|
||||
|
Loading…
Reference in New Issue
Block a user