src/Ciconia/Renderer/HtmlRenderer.php
public function renderLink($content, array $options = array())
    {
        $options = $this->createResolver()
            ->setRequired(array('href'))
            ->setDefaults(array('href' => '#', 'title' => ''))
            ->setAllowedTypes(array('href' => 'string', 'title' => 'string'))
            ->resolve($options);

        $tag = new Tag('a');
        $tag->setText($content);
        $tag->setAttribute('href', $options['href']);

        if ($options['title']) {
            $tag->setAttribute('title', $options['title']);
        }

        $this->getEmitter()->emit('tag', [$tag]);

        return $tag->render();
    }
public function renderLink($content, array $options = array())
    {
        $options = $this->createResolver()
            ->setRequired(array('href'))
            ->setDefaults(array('href' => '#', 'title' => ''))
            ->setAllowedTypes(array('href' => 'string', 'title' => 'string'))
            ->resolve($options);

        $tag = new Tag('a');
        $tag->setText($content);
        $tag->setAttribute('href', $options['href']);

        if ($options['title']) {
            $tag->setAttribute('title', $options['title']);
        }

        $this->getEmitter()->emit('tag', [$tag]);

        return $tag->render();
    }
@param string|Text $content
@param array       $options

@return string