You are here

class hashtags_replace_parameter in Hashtags 6

Hierarchy

Expanded class hierarchy of hashtags_replace_parameter

File

./hashtags.module, line 217

View source
class hashtags_replace_parameter {
  function replace($matches) {
    if (isset($this->hashtags_tids)) {
      $hashtags_tids = $this->hashtags_tids;
    }
    $first_delimeter = $matches[1];
    $hashtag_name = $matches[2];
    $hashtag_tid = $hashtags_tids[strtolower($hashtag_name)];
    $hashtag_link = l($hashtag_name, 'taxonomy/term/' . $hashtag_tid, array(
      'attributes' => array(
        'class' => 'hashtag',
      ),
    ));
    return $first_delimeter . $hashtag_link;
  }

}

Members