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:

Forum Module /

Discuss the Forum Module.

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

Get link of forum thread


Go to End


3 Posts   1138 Views

Avatar
DeklinKelly

Community Member, 197 Posts

17 February 2011 at 9:06am

How can I get the link for this forum thread?

	$Thread = DataObject::get_one('Post', " `Title` LIKE '". $Title ."' ", '`Created` ASC');

Avatar
DeklinKelly

Community Member, 197 Posts

17 February 2011 at 2:06pm

Here is the answer:

$Thread->Link()

Avatar
Willr

Forum Moderator, 5523 Posts

18 February 2011 at 6:53pm

Good work answering your own thread :) Most objects in SilverStripe should have a Link() function defined if they are designed to be viewable. It's kind of a convention so you should be able to call that on quite a few things.