You are here

function fonts_com_get_project_by_id in @font-your-face 7.2

Gets list of projects from API.

3 calls to fonts_com_get_project_by_id()
fonts_com_fontyourface_status in modules/fonts_com/fonts_com.module
Implements hook_fontyourface_status().
fonts_com_project_edit_form_submit in modules/fonts_com/fonts_com.module
Saves changes to project.
fonts_com_project_info_form in modules/fonts_com/fonts_com.module
Returns project info form array.

File

modules/fonts_com/api.inc, line 389
API functions.

Code

function fonts_com_get_project_by_id($project_id) {
  $projects = fonts_com_get_projects();
  if (count($projects) > 0) {
    foreach ($projects as $project) {
      if ($project->ProjectKey == $project_id) {
        return $project;
      }

      // if
    }

    // foreach
  }

  // if
  return FALSE;
}