| 1 |
<?php |
<?php |
| 2 |
// $Id: taxonomy_other.module,v 1.3 2008/06/15 16:23:46 rellis Exp $ |
// $Id: taxonomy_other.module,v 1.1.2.5 2008/08/06 23:07:13 rellis Exp $ |
| 3 |
|
|
| 4 |
/** |
/** |
| 5 |
* @file |
* @file |
| 352 |
*/ |
*/ |
| 353 |
function taxonomy_other_taxonomy($op, $type, $array) { |
function taxonomy_other_taxonomy($op, $type, $array) { |
| 354 |
if ($op == 'delete') { |
if ($op == 'delete') { |
| 355 |
if ($type = 'vocabulary') { |
if ($type == 'vocabulary') { |
| 356 |
$terms = taxonomy_other_get_tids($array['vid']); |
$terms = taxonomy_other_get_tids($array['vid']); |
| 357 |
$d = implode(',', array_pad(array(), count($terms), '%d')); |
if (!empty($terms)) { |
| 358 |
db_query("DELETE FROM {taxonomy_other_term} WHERE tid IN (" . $d . ")", $terms); |
$d = implode(',', array_pad(array(), count($terms), '%d')); |
| 359 |
|
db_query("DELETE FROM {taxonomy_other_term} WHERE tid IN (" . $d . ")", $terms); |
| 360 |
|
} |
| 361 |
} |
} |
| 362 |
elseif ($type = 'term') { |
elseif ($type == 'term') { |
| 363 |
db_query("DELETE FROM {taxonomy_other_term} WHERE tid = '%d'", $array['tid']); |
db_query("DELETE FROM {taxonomy_other_term} WHERE tid = '%d'", $array['tid']); |
| 364 |
} |
} |
| 365 |
} |
} |