[Plugin: Widget Logic] Need help with Child page and Custom Post Type
-
I currently have widget logic working with this:
global $post; return (in_array(63,get_post_ancestors($post)));
but I would like it to also show on a custom post type. If I use the following alone, it works:
get_post_type() == ‘sermon’
But if I put them together I get an error.
global $post; return (in_array(63,get_post_ancestors($post))); && get_post_type() == ‘sermon’
I get this error:
Parse error: syntax error, unexpected T_BOOLEAN_AND in /var/www/vhosts/onelife.tv/httpdocs/wp-content/plugins/widget-logic/widget_logic.php(270) : eval()’d code on line 1
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘[Plugin: Widget Logic] Need help with Child page and Custom Post Type’ is closed to new replies.