Uname: Linux webm021.cluster127.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
Software: Apache
PHP version: 5.4.45 [ PHP INFO ] PHP os: Linux
Server Ip: 54.36.91.62
Your Ip: 216.73.216.52
User: matthif (139342) | Group: users (100)
Safe Mode: OFF
Disable Function:
_dyuweyrj4,_dyuweyrj4r,dl

name : post.php
<?php

/**
 * Set the default editor mode for the page post type to `template-locked`.
 *
 * Note: This backports into `create_initial_post_types` in WordPress Core.
 *
 * @param array $args Array of post type arguments.
 * @return array Updated array of post type arguments.
 */
function gutenberg_update_page_editor_support( $args ) {
	if ( empty( $args['supports'] ) ) {
		return $args;
	}

	$editor_support_key = array_search( 'editor', $args['supports'], true );
	if ( false !== $editor_support_key ) {
		unset( $args['supports'][ $editor_support_key ] );
		$args['supports']['editor'] = array(
			'default_mode' => 'template-locked',
		);
	}

	return $args;
}
add_action( 'register_page_post_type_args', 'gutenberg_update_page_editor_support' );
© 2026 XylotrechusZ