Scoped GlideSPScriptable - getPortalRecord()

Returns the portal's GlideRecord.

Table 1. Parameters
Name Type Description
None
Table 2. Returns
Type Description
GlideRecord The portal record
//Server script
(function() {
    var portalGr = $sp.getPortalRecord();
    data.logo = portalGr.getDisplayValue("logo");
    data.homepage = portalGr.getDisplayValue("homepage.id");
})();

//HTML template
<div>
    <img ng-src="{{::c.data.logo}}" />
    <a href="?id={{::c.data.homepage}}">Click here to go home</a>
</div>