$object->getsitegroup

Name

$object->getsitegroup -- Get the sitegroup a record belongs to

Synopsis

int $object->getsitegroup(void);

Description

Minimum version: Midgard 1.4 (Bifrost)

Retrieves the id of the sitegroup the record belongs to.

Returns the sitegroup id if successfull. Returns false on failure.

Method available for: article, attachment, element, event, event_member, group, host, member, page, pageelement, pagelink, person, preference, snippet, snippetdir, style and topic records.

Example

<?php
  $topic = mgd_get_topic(123) # topic with id 123 must exist.
  echo $topic->name . " is in sitegroup " . $topic->getsitegroup();
?>