You are here

function biblio_get_contributor_by_name in Bibliography Module 6.2

Same name and namespace in other branches
  1. 6 biblio.contributors.inc \biblio_get_contributor_by_name()
  2. 7 includes/biblio.contributors.inc \biblio_get_contributor_by_name()
  3. 7.2 biblio.module \biblio_get_contributor_by_name()

Retrieves biblio contributor object based on exact match of contributor name.

// @todo: What happens if array or non-existant name string passed?

Parameters

string $name: Name of a contributor.

Return value

object|? A contributor object if found; otherwise ??

File

includes/biblio.contributors.inc, line 37
Functions related to contributors in Drupal biblio module.

Code

function biblio_get_contributor_by_name($name) {
  return db_fetch_object(db_query("SELECT * FROM {biblio_contributor_data} bcd WHERE bcd.name = '%s'", array(
    $name,
  )));
}