Hiya,
I'm sure the above is a stupid question. Of course these methods should work, in fact I'm sure this was working an hour ago.
I made a Testimonial class, extending DataObject. I also made a TestimonialPage extending Page where these are stored in a dataobject_manager grid.
I have added a simple method to Page.php controller so that all pages that extend page, have access to this:
public function getTestimonials() {
return DataObject::get_one("Testimonial");
}
That's it. I do a <% control getTestimonials %> on my template and all I get is a blank page. If I comment out the return above, all is OK (except no data of course). No errors, even in Dev mode.
Any thoughts?
Cheers
Aaron