« Zurück

Has Block Content Snippet

Version:
0.0.3
State:
Stable
Release Date:
2020/06/27
License:
GPL
Authors:
Christian M. Stefan (Stefek), bernd
Description language:
EN | DE
Description EN:
Checks if there is content in a certain template block.
In your template or a code2 section, use the following PHP code:

if (has_block_content(1)) {
...your code here which will be executed if there is content in block 1
}


Description DE:
Prüft, ob in einem bestimmter Templateblock Inhalte vorhanden sind.
Im Template oder einem Code2-Abschnitt folgenden PHP-Code verwenden:

if (has_block_content(1)) {
...Code, der ausgeführt wird, wenn im Block 1 Inhalte sind
}