Hello everybody!
I've been using processwire for more than 1 year and I love it.
Recently I've had this problem:
I have some pages using the basic template with headline, body and images.
I need to access their data from an external page that I put outside the templates folder.
In this external page I initialize the engine this way:
include("../../index.php");
And I get the page I need like that:
$internalpage=$wire->pages->find("id=".$pageid.",include=all")->get(0);
I can read the headline and the body of the page normally, but the images array is NULL
I try to access the images array as usual:
foreach($internalpage->images as $image){
...
}
The images field is called "images", like the default one.
I've also tried to get the field list of the page, I get the field images but still it is null.
I checked the admin and the images are correctly uploaded on the page I try to access.
What am I doing wrong?
Thank You!