I'm using the subsites module (or rather a modified version of it!) and am putting my subsites in sub domains, eg:
silverstripe.com - main site
site1.silverstripe.com - sub site
in my theme, I'd like to link back to my main site, dynamically if possible. Is there a function/setting in $Site.Config that stores the main site URL?