You are here

function biblio_delete_keywords in Bibliography Module 7

Same name and namespace in other branches
  1. 6.2 includes/biblio.keywords.inc \biblio_delete_keywords()
  2. 6 biblio.keywords.inc \biblio_delete_keywords()
  3. 7.2 includes/biblio.keywords.inc \biblio_delete_keywords()

Delete all keywords references for a given node.

The actual keywords remain in the biblio_keyword_data table.

Parameters

$node:

Return value

The number of links removed

2 calls to biblio_delete_keywords()
BiblioKeywordWebTestCase::testBiblioUpdateKeywords in tests/BiblioKeywordWebTestCase.test
biblio_delete in ./biblio.module
Implements hook_delete().

File

includes/biblio.keywords.inc, line 359
Contains all keyword related functions.

Code

function biblio_delete_keywords($node) {
  $count = db_delete('biblio_keyword')
    ->condition('nid', $node->nid)
    ->execute();
  return $count;
}