Block nur bei einem Inhalstyp anzeigen

Da die Anfrage SOOOOOOO oft kommt und mans nicht jedes mal schreiben will
<?php
//$Id$
function arg_is_type($type) {
if (arg(0) == 'node' && is_numeric(arg(1))) {
$node = node_load(arg(1));
return $node->type == $type;
}
return false;
}
?>

Einfach dieser Funktion den type mitgeben und zurückkommt, ob man in diesem Typ ist

Comments

Block nur bei einem Inhalstyp anzeigen - Good post. Thanks.

Add new comment