Guys
After having created a lot of working page types in ss3.1 I now realise that quite a few page types should have the Foundation Orbit slider on them. I therefore cur it out of one working page type and created a new intermediate object OrbitPage.php (which extends Page) and then I extended my pages that need a slider on OrbitPage.
OrbitPage uses another object, OrbitImage, which uses gridfield sorting and a few other things. In OrbitImage I had the following function derived from http://www.silverstripe.org/general-questions/show/20603
function getNextSortID() {
$getDataList = $this->Page()->OrbitImage();
if (!$getDataList || $getDataList->Count() == 0) {
return NULL;
} else {
return $getDataList->first()->SortID + 1
}
SS3 now baulks on the $this->Page() method which worked when this function was called in reference to a page type one object separated from Page.php. Now I have say, HeroPage extending OrbitPage extending Page, I can't find the right site tree method. $this->OrbitPage() does not work
HELP!!!