Browse: Home / Classes / LearnDash_Gutenberg_Block /

LearnDash_Gutenberg_Block::block_attributes_get_post_id

LearnDash_Gutenberg_Block::block_attributes_get_post_id( array $block_attributes = array(),  string $post_prefix = '' )

Utility function to determine the Post ID from the block attributes.


Description #


Parameters #

$block_attributes

(array) (Optional) The block attributes.

Default value: array()

$post_prefix

(string) (Optional) The post prefix to use. Example: 'course', 'quiz', 'group', etc.

Default value: ''


Return #

(int) Post ID.


Source #

File: includes/gutenberg/lib/class-learndash-gutenberg-block.php


Changelog #

Changelog
Version Description
4.0.0 Introduced.