You are here

public function nexcloud::clear_tags in filedepot 7

Same name and namespace in other branches
  1. 6 nexcloud.class.php \nexcloud::clear_tags()
1 call to nexcloud::clear_tags()
nexcloud::update_tags in ./nexcloud.class.php

File

./nexcloud.class.php, line 433
nexcloud.class.php Tag Cloud class for the filedepot module

Class

nexcloud
@file nexcloud.class.php Tag Cloud class for the filedepot module

Code

public function clear_tags($itemid) {

  // Retrieve the current assigned tags - these are the tags to update
  $currentTags = db_query("SELECT tags FROM {nextag_items} WHERE type=:type AND itemid=:item", array(
    ':type' => $this->_type,
    ':item' => $itemid,
  ))
    ->fetchField();
  $currentTags = explode(',', $currentTags);
  $this
    ->remove_accessmetrics($itemid, $currentTags);
  db_query("DELETE FROM {nextag_items} WHERE itemid = :item", array(
    ':item' => $itemid,
  ));
}