You are here

function _bbcode_tips in Bbcode 7

Implement hook_filter_FILTER_tips

1 string reference to '_bbcode_tips'
bbcode_filter_info in ./bbcode.module
Implement hook_filter_info

File

./bbcode.module, line 90

Code

function _bbcode_tips($filter, $format, $long = FALSE) {
  if ($long) {
    include_once DRUPAL_ROOT . '/' . drupal_get_path('module', 'bbcode') . '/bbcode-help.inc';
    return _bbcode_filter_tip();
  }
  else {
    $output = t('You can use !BBCode tags in the text.', array(
      '!BBCode' => l(t('BBCode'), 'filter/tips/' . $format->format, array(
        'fragment' => 'filter-' . $format->format,
      )),
    ));
    if ($filter->settings['bbcode_make_links']) {
      $output .= ' ' . t('URLs will automatically be converted to links.');
    }
    return $output;
  }
}