Jump to content

Recommended Posts

Posted

Hi,

I'm creating my own theme and need help with showing all pages from a parent that's called recommendations. 

Thanks for the help.

 

Posted

One way of doing it would be:

foreach($pages->find("parent=recommendations") as $child){
  echo $child->title;
  }

but there are many more ways to accomplish that goal.

Best starting point would be to read the docs of selectors

  • Like 5
Posted

One more question. I'm trying to find a way to show the URL of an image that's in the page. The image field is called Image. I tried

<?php echo $child->Image;?>

and all it will output is the name of the file (image.jpg).

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
  • Recently Browsing   0 members

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