You are here

function hosting_site_update in Hosting 5

Same name and namespace in other branches
  1. 6.2 site/hosting_site.nodeapi.inc \hosting_site_update()
  2. 7.4 site/hosting_site.nodeapi.inc \hosting_site_update()
  3. 7.3 site/hosting_site.nodeapi.inc \hosting_site_update()

File

site/hosting_site.module, line 398

Code

function hosting_site_update(&$node) {

  // if this is a new node or we're adding a new revision,
  if ($node->revision) {
    hosting_site_insert($node);
  }
  else {
    $client = hosting_get_client($node->client);
    $node->client = $client->nid;
    db_query("UPDATE {hosting_site} SET client = %d, db_server = %d, platform = %d, last_cron = %d, status = %d, profile = %d, language = '%s', verified = %d WHERE vid=%d", $node->client, $node->db_server, $node->platform, $node->last_cron, $node->site_status, $node->profile, $node->language, $node->verified, $node->vid);
  }
  if (!$node->no_verify) {
    hosting_add_task($node->nid, 'verify');
  }
}