Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

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.

Customising the CMS /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

ModelAdmin and Frontend Integration


Go to End


2 Posts   2396 Views

Avatar
teejay

Community Member, 63 Posts

21 March 2009 at 9:41pm

Hi guys. I have played a little bit around with model admin, and yeah I think its a really cool feature. I have just on problem. How can i display my data on a page in the frontend ?

THX a lot

Thomas

Avatar
teejay

Community Member, 63 Posts

21 March 2009 at 9:53pm

Ok ok think first before posting. Just create a new page and add a custom query to the controller

function TestQuery (){
$list = DataObject::get('Product');
return $list;
}

<% control TestQuery %>
<p>$Name ... $Category.Title</p>
<% end_control %>

and it works like a charm