code/SiteTreeSubsites.php
/**
	 * Returns the RelatedPageLink objects that are reverse-associated with this page.
	 */
Returns the RelatedPageLink objects that are reverse-associated with this page.
Returns the RelatedPageLink objects that are reverse - associated with this page .
function ReverseRelated() {
		return DataObject::get('RelatedPageLink', "\"RelatedPageLink\".\"RelatedPageID\" = {$this->owner->ID}
			AND R2.\"ID\" IS NULL", '',
			"INNER JOIN \"SiteTree\" ON \"SiteTree\".\"ID\" = \"RelatedPageLink\".\"MasterPageID\"
			LEFT JOIN \"RelatedPageLink\" AS R2 ON R2.\"MasterPageID\" = {$this->owner->ID}
			AND R2.\"RelatedPageID\" = \"RelatedPageLink\".\"MasterPageID\"
			"
		);
	}
function ReverseRelated ( ) { return DataObject :: get ( 'RelatedPageLink' , " \" RelatedPageLink \" . \" RelatedPageID \"  =  { $ this -> owner -> ID } 
			AND R2. \" ID \"  IS NULL " , '' , " INNER JOIN  \" SiteTree \"  ON  \" SiteTree \" . \" ID \"  =  \" RelatedPageLink \" . \" MasterPageID \" 
			LEFT JOIN  \" RelatedPageLink \"  AS R2 ON R2. \" MasterPageID \"  =  { $ this -> owner -> ID } 
			AND R2. \" RelatedPageID \"  =  \" RelatedPageLink \" . \" MasterPageID \" " ) ; }
Returns the RelatedPageLink objects that are reverse-associated with this page.
Returns the RelatedPageLink objects that are reverse - associated with this page .