Hello
tried to create a hook element with the following code but I’m getting some errors – hope somebody can help.
Thanks
<?php
global $post;
$pid = (int) $post->post_parent;
echo do_shortcode('[ gallery id="'.$pid.'" numberposts="3" ]');
?>
the error is as follows: Parse error: syntax error, unexpected 'gallery' (T_STRING), expecting ',' or ')' in /Users/Marco/Sites/cms/wp-mmjaeger/wp-content/plugins/generatepress-premium/elements/class-hooks.php(180) : eval()'d code on line 10