You are here

function checklistapi_checklist_load in Checklist API 7

Same name and namespace in other branches
  1. 8 checklistapi.module \checklistapi_checklist_load()

Loads a checklist object.

Parameters

string $id: The checklist ID.

Return value

ChecklistapiChecklist|false A fully-loaded checklist object, or FALSE if the checklist is not found.

5 calls to checklistapi_checklist_load()
checklistapi_checklist_clear_confirm in ./checklistapi.pages.inc
Page callback: Form constructor for "Clear saved progress" confirmation form.
checklistapi_checklist_form in ./checklistapi.pages.inc
Page callback: Form constructor for the checklist form.
checklistapi_report_form in ./checklistapi.admin.inc
Page callback: Form constructor for the report form.
drush_checklistapi_info_validate in ./checklistapi.drush.inc
Implements drush_hook_COMMAND_validate().
drush_checklistapi_list in ./checklistapi.drush.inc
Drush callback for checklist listing.

File

./checklistapi.module, line 47
An API for creating fillable, persistent checklists.

Code

function checklistapi_checklist_load($id) {
  $definition = checklistapi_get_checklist_info($id);
  return $definition ? new ChecklistapiChecklist($definition) : FALSE;
}