This project has moved and is read-only. For the latest updates, please go here.

Get Site Title

Aug 2, 2012 at 4:04 AM

This is probably a real noobie question but,.. How to I get the title of my current site so I can add it to list column?

Aug 2, 2012 at 1:51 PM

You don't need SPServices for that. You can do it with jQuery.  The site title should be at the top of each page with an tag ID of 'ctl00_PlaceHolderSiteName_onetidProjectPropertyTitle' so referencing that element's text property is simply...

var strSiteTitle = $("#ctl00_PlaceHolderSiteName_onetidProjectPropertyTitle").text();

Aug 2, 2012 at 9:14 PM

Thanks, just knew I was over thinking it :-)