Jump to content

display fields from an other page


yesjoar
 Share

Recommended Posts

Hey there,

I've started a new project today and now I have a small issue.

I have a page (id: 1012) with a select-field (type: page) to display some other pages. In my case the other pages a team member.

So when I go to my page with the id 1012 and say

echo $page->fieldname;

So it returns me the ID (1046) from the page, which I have chosen in my field.

Now i want to display some other fields from the page with the id 1046, but it doesn't work for me.

I tried:

$apID = $page->myfield; // returns the correct ID
$test = $pages->get($apID);
echo $test->title;

But this doesnt work.

When I say get(1046) all workes fine.

Any idea whats the problem is?

Thanks (:

y.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...