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're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Archive /

Our old forums are still available as a read-only archive.

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

How to integrate with SMF ?

Go to End

2 Posts   2110 Views


Community Member, 49 Posts

31 August 2008 at 10:40am

I am using one function call in php from smf that is SSI that allows me to show th elast messages from the forum in another page.

How can this be used with siverstripe ?

Matt Hardwick

Community Member, 61 Posts

4 September 2008 at 5:23am

Edited: 05/09/2008 10:17am

Edit your /mysite/code/Page.php (or if you've made your own page class edit that).

On the top line after the opening PHP tag include SSI.php
for example:


Then before the final } add this:

function Content()
$content = $this->Content;
$content = str_replace('[[recentPosts]]', ssi_recentPosts(), $content);
return $content;

Then add [[recentPosts]] somewhere on your content, and you should get the function recentPosts returned. Of course you can name it something else and call a different function.

If you're interested my Page.php looks like this:

If you get stuck let me know.