23478 Posts in 18941 Topics by 2878 members
|Go to End|
25 April 2012 at 7:15pm
So, I'm using a controller to provide services to some Ajax based pages. I'm also using subsites. What I'd like to do is to allow each site to know what subsite its in, so it can make some adjustments.
So, question; is there a way, within a controller, to determine what subsite is currently being served?
Thanks in advance,
26 April 2012 at 9:53am
Figured it out. For those of you who have the same requirement, just do:-
Then, you can, perhaps, differentiate using
$site = Subsite::currentSubsite();
$title = $site->Title;
|Go to Top|