breadcrumb – Can not get the parent page identifier

I'm using the free-blog theme and I've created a menu:

page A
page B
Child page A
Child page B
Child page C
Page c
Child Post A
Child Post B

Now, I want to create a piece of bread. as_
Home-> Page B -> Child page A

Until now, it is not so difficult. I can get the child page ID without a problem, but I can not get the parent page ID. He is always 0.

I've tried it with

$ post_id = get_queried_object_id ();
$ post = get_post ($ post_id);
$ parent_link = get_permalink ($ post-> post_parent);
$ parent_title = get_the_title ($ post-> post_parent);

$ post-> post_parent is always 0

so I tried

$ parents = get_post_ancestors (post_id);

but parents also count 0. Also


So I wonder if I'm doing anything wrong when I've created my menu. In child message A, I tried to select the category, but the parent value is always 0