Hi, Please, help. How I can get first 3 objects without first
public function LatestSlider($num=4) {
$sliders = DataObject::get("NewsArticle","Slider=true","OriginalPublishedDate DESC","",$num);
return $sliders;
}
Don't get first one object for slider:
<a href="post.html" class="active"><span class="slider-overlay">Object_first</a>
<a href="post.html"><span class="slider-overlay">Object_second ....</a>
We've moved the forum!
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Maybe something like...
return $sliders->getRange(1,3);
Thank you, it' work