|
@@ 597-612 (lines=16) @@
|
| 594 |
|
* @return mixed |
| 595 |
|
* @deprecated 1.9 Use \ElggSite::getEntities() |
| 596 |
|
*/ |
| 597 |
|
function get_site_objects($site_guid, $subtype = "", $limit = 10, $offset = 0) { |
| 598 |
|
elgg_deprecated_notice('get_site_objects() is deprecated. Use \ElggSite::getEntities()', 1.9); |
| 599 |
|
$site_guid = (int)$site_guid; |
| 600 |
|
$limit = (int)$limit; |
| 601 |
|
$offset = (int)$offset; |
| 602 |
|
|
| 603 |
|
return elgg_get_entities_from_relationship(array( |
| 604 |
|
'relationship' => 'member_of_site', |
| 605 |
|
'relationship_guid' => $site_guid, |
| 606 |
|
'inverse_relationship' => true, |
| 607 |
|
'type' => 'object', |
| 608 |
|
'subtype' => $subtype, |
| 609 |
|
'limit' => $limit, |
| 610 |
|
'offset' => $offset |
| 611 |
|
)); |
| 612 |
|
} |
| 613 |
|
|
| 614 |
|
/** |
| 615 |
|
* Get the sites this object is part of |
|
@@ 649-664 (lines=16) @@
|
| 646 |
|
* @return \ElggSite[]|false On success, an array of \ElggSites |
| 647 |
|
* @deprecated 1.9 Use \ElggEntity::getSites() |
| 648 |
|
*/ |
| 649 |
|
function get_user_sites($user_guid, $limit = 10, $offset = 0) { |
| 650 |
|
elgg_deprecated_notice('get_user_sites() is deprecated. Use \ElggEntity::getSites()', 1.9); |
| 651 |
|
$user_guid = (int)$user_guid; |
| 652 |
|
$limit = (int)$limit; |
| 653 |
|
$offset = (int)$offset; |
| 654 |
|
|
| 655 |
|
return elgg_get_entities_from_relationship(array( |
| 656 |
|
'site_guids' => ELGG_ENTITIES_ANY_VALUE, |
| 657 |
|
'relationship' => 'member_of_site', |
| 658 |
|
'relationship_guid' => $user_guid, |
| 659 |
|
'inverse_relationship' => false, |
| 660 |
|
'type' => 'site', |
| 661 |
|
'limit' => $limit, |
| 662 |
|
'offset' => $offset, |
| 663 |
|
)); |
| 664 |
|
} |
| 665 |
|
|
| 666 |
|
/** |
| 667 |
|
* Determines whether or not the specified user can edit the specified piece of extender |