WordPress Version: 5.5
/**
* Registers the `core/calendar` block on server.
*/
function register_block_core_calendar()
{
register_block_type_from_metadata(__DIR__ . '/calendar', array('render_callback' => 'render_block_core_calendar'));
}
The timeline below displays how wordpress function register_block_core_calendar has changed across different WordPress versions. If a version is not listed, refer to the next available version below.
/**
* Registers the `core/calendar` block on server.
*/
function register_block_core_calendar()
{
register_block_type_from_metadata(__DIR__ . '/calendar', array('render_callback' => 'render_block_core_calendar'));
}
/**
* Registers the `core/calendar` block on server.
*/
function register_block_core_calendar()
{
register_block_type('core/calendar', array('attributes' => array('align' => array('type' => 'string', 'enum' => array('left', 'center', 'right', 'wide', 'full')), 'className' => array('type' => 'string'), 'month' => array('type' => 'integer'), 'year' => array('type' => 'integer')), 'render_callback' => 'render_block_core_calendar'));
}
/**
* Registers the `core/calendar` block on server.
*/
function register_block_core_calendar()
{
register_block_type('core/calendar', array('attributes' => array('align' => array('type' => 'string'), 'className' => array('type' => 'string'), 'month' => array('type' => 'integer'), 'year' => array('type' => 'integer')), 'render_callback' => 'render_block_core_calendar'));
}