You are here

function _hosting_get_locked_platforms in Hosting 6.2

Same name and namespace in other branches
  1. 7.4 platform/hosting_platform.module \_hosting_get_locked_platforms()
  2. 7.3 platform/hosting_platform.module \_hosting_get_locked_platforms()

Small helper function to get platforms that have been locked.

1 call to _hosting_get_locked_platforms()
_hosting_platform_is_locked in platform/hosting_platform.module
Small helper function to check if a platform is locked.

File

platform/hosting_platform.module, line 236
Platform node type definition.

Code

function _hosting_get_locked_platforms() {
  $return = array();
  $result = db_query("SELECT n.nid, n.title FROM {node} n LEFT JOIN {hosting_platform} h ON n.nid = h.nid \n                      WHERE n.type='platform' AND n.status=1 AND h.status = %d ORDER BY n.title", HOSTING_PLATFORM_LOCKED);
  while ($server = db_fetch_object($result)) {
    $return[$server->nid] = $server->title;
  }
  return $return;
}