Hi there,
I have many-many DOM where Logos are related to NewsPages. I would like to get a NewsPages where LogoID is unique (would like to show only one newspage where is the same LogoID). How could I use array_unique with this dataobject set?:
function GetNewsByLogos() {
$doSet = DataObject::get(
$callerClass = "NewsPage",
$filter = "`SiteTree`.ParentID = 111 AND `NewsPage`.LogoID != '' ",
$sort = "",
$join = "",
$limit = ""
);
return $doSet ? $doSet : false;
}
Thanks for any help!