I have several pages with a parent. So, $post->post_parent should be different than 0, right?
echo $post->post_parent;
Is returning 0.
Thing is, this is only happening in one post category. Do I need to declare that a page has a parent elsewhere? I do it from within the edit page form of that page.
Thanks!
$post
before you try to call it. Ensure debug mode is enabled, and report any PHP notices generated. Also: please edit your question to include your actual code, in context.