function glossary_filter_tips in Glossary 6
Same name and namespace in other branches
- 5.2 glossary.module \glossary_filter_tips()
- 5 glossary.module \glossary_filter_tips()
File
- ./
glossary.module, line 396 - Glossary terms will be automatically marked with links to their descriptions.
Code
function glossary_filter_tips($delta, $format, $long = FALSE) {
$block_tags = explode(' ', variable_get("glossary_blocking_tags_{$format}", 'abbr acronym'));
$standard_blocks = array(
'a',
);
foreach ($standard_blocks as $tag) {
if (!in_array($tag, $block_tags)) {
$block_tags[] = check_plain($tag);
}
}
foreach ($block_tags as $key => $tag) {
if ($tag[0] == '.') {
$block_tags[$key] = 'span class="' . check_plain(drupal_substr($tag, 1)) . '"';
}
}
sort($block_tags, SORT_STRING);
$blocked = implode(', ', $block_tags);
$more = ' ' . t('Additionally, these HTML elements will not be scanned: %blocked.', array(
'%blocked' => $blocked,
));
if ($long) {
return t('The Glossary module will automatically mark terms that have been defined in the glossary vocabulary with links to their descriptions. These marks depend on the settings and may be a superscript character or an icon, or the term may be turned into an acronym, cite, or abbreviation. If there are certain phrases or sections of text that should be excluded from glossary marking and linking, use the special markup, [no-glossary] ... [/no-glossary].') . $more;
}
else {
return t('Glossary terms will be automatically marked with links to their descriptions. If there are certain phrases or sections of text that should be excluded from glossary marking and linking, use the special markup, [no-glossary] ... [/no-glossary].') . $more;
}
}