You are here

function tft_is_archive_folder in Taxonomy File Tree 7.2

Same name and namespace in other branches
  1. 7 tft.module \tft_is_archive_folder()
2 calls to tft_is_archive_folder()
tft_delete_term_form in includes/tft.pages.inc
Form: delete a term.
tft_edit_term_form in includes/tft.pages.inc
Form: edit a term.

File

./tft.module, line 1224
Hook implementations and module logic for TFT.

Code

function tft_is_archive_folder($tid) {

  // Must be a direct child.
  if (tft_get_depth($tid) == 1) {
    $title = db_select('taxonomy_term_data', 't')
      ->fields('t', array(
      'name',
    ))
      ->condition('tid', $tid)
      ->execute()
      ->fetchField();
    if ($title == t('Archives')) {
      return TRUE;
    }
  }
  return FALSE;
}