WP_Block_List::offsetExists()
Returns true if a block exists by the specified block index, or false otherwise.
Метод класса: WP_Block_List{}
Хуков нет.
Возвращает
true|false
. Whether block exists.
Использование
$WP_Block_List = new WP_Block_List(); $WP_Block_List->offsetExists( $index );
- $index(строка) (обязательный)
- Index of block to check.
Список изменений
С версии 5.5.0 | Введена. |
Код WP_Block_List::offsetExists() WP Block List::offsetExists WP 6.2.2
public function offsetExists( $index ) { return isset( $this->blocks[ $index ] ); }