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.

All other Modules /

Discuss all other Modules here.

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

subsite specific template methods

Go to End

2 Posts   1006 Views


Community Member, 545 Posts

11 January 2011 at 7:46am

I'm just wondering if there are any methods in subsite accessible from the template. I'd like to show slightly different information in my page footer on my subsites than my main site. So an <% if Subsite %> type methods would be ideal



Community Member, 88 Posts

12 January 2011 at 5:33am

I have added add a Method to my Page_Controller as follows:

	public function IsOnSubsite(){
		return is_object(Subsite::currentSubsite())?1:0;

Some of the Subsite variables/methods you can also access with $Subsite.currentSubsiteID, but I don't know which and how reliable they are.