src/Sonic/Helper.php
public function link_for($file_name)
    {
        try {
            // Check if file exists
            $content = $this->app['filesystem']->parse($this->app['settings']['sonic.content_dir'] . '/' . $file_name);

            // Get file title and URL and return
            $title   = $content['meta']['title'];
            $url     = $this->url_for($file_name);
            return sprintf('<a href="%s"> ' . $title . ' </a>', $url);
        }
        catch (\Exception $e) {
            $this->app['router']->error($e);
        }
        return null;
    }
public function link_for($file_name)
    {
        try {
            // Check if file exists
            $content = $this->app['filesystem']->parse($this->app['settings']['sonic.content_dir'] . '/' . $file_name);

            // Get file title and URL and return
            $title   = $content['meta']['title'];
            $url     = $this->url_for($file_name);
            return sprintf('<a href="%s"> ' . $title . ' </a>', $url);
        }
        catch (\Exception $e) {
            $this->app['router']->error($e);
        }
        return null;
    }
Returns a HTML <a> for a given filename in the 'content' directory

@param  string      $file_name
@return string|null