function lingotek_get_communities in Lingotek Translation 6
Same name and namespace in other branches
- 7.2 lingotek.api.inc \lingotek_get_communities()
- 7.3 lingotek.api.inc \lingotek_get_communities()
- 7.4 lingotek.api.inc \lingotek_get_communities()
- 7.5 lingotek.remote.inc \lingotek_get_communities()
- 7.6 lingotek.remote.inc \lingotek_get_communities()
3 calls to lingotek_get_communities()
File
- ./
lingotek.api.inc, line 225
Code
function lingotek_get_communities() {
global $_lingotek_client;
$options = array();
if (!$_lingotek_client
->canLogIn()) {
return $options;
}
$list_communities = $_lingotek_client
->request("listCommunities", array());
if ($list_communities->results == "success") {
foreach ($list_communities->communities as $community) {
$options[$community->id] = t($community->name);
}
}
return $options;
}