function hosting_get_default_profile in Hosting 7.3
Same name and namespace in other branches
- 6.2 package/hosting_package.module \hosting_get_default_profile()
- 7.4 package/hosting_package.module \hosting_get_default_profile()
@todo document this function
2 calls to hosting_get_default_profile()
- hosting_site_available_options in site/hosting_site.form.inc 
- Pass in a site node and return an array of valid options for it's fields.
- hosting_site_form in site/hosting_site.form.inc 
- Implements hook_form().
File
- package/hosting_package.module, line 237 
- Defines package node types
Code
function hosting_get_default_profile($default = NULL) {
  if ($p = hosting_get_package(variable_get('hosting_default_profile', 'standard'), 'profile')) {
    return $p->nid;
  }
  elseif ($p = hosting_get_package('standard', 'profile')) {
    return $p->nid;
  }
  elseif ($p = hosting_get_package('default', 'profile')) {
    return $p->nid;
  }
  return $default;
}