You are here

function hosting_platform_insert in Hosting 6.2

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

Implementation of hook_insert().

1 call to hosting_platform_insert()
hosting_platform_update in platform/hosting_platform.module
Implementation of hook_update().

File

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

Code

function hosting_platform_insert($node) {
  if (!isset($node->no_verify)) {
    hosting_add_task($node->nid, 'verify');
  }
  db_query("INSERT INTO {hosting_platform} (vid, nid, publish_path, makefile, verified, web_server, status, make_working_copy) VALUES (%d, %d, '%s', '%s', %d, %d, %d, %d)", $node->vid, $node->nid, $node->publish_path, $node->makefile, $node->verified, $node->web_server, $node->platform_status, $node->make_working_copy);
  if (!$node->old_vid) {
    hosting_context_register($node->nid, 'platform_' . preg_replace("/[!\\W]/", "", $node->title));
  }
}