예제 #1
0
파일: ExtractorTest.php 프로젝트: n8b/VMN
 /**
  * @covers ::linkifyAll
  * @covers ::getHTML
  * @dataProvider providerLinkifyAll
  */
 public function testLinkifyAll($input, $output)
 {
     $this->object->setText($input);
     $this->assertEquals($this->object->linkifyAll()->getHTML(), $output);
 }
예제 #2
0
파일: Extractor.php 프로젝트: n8b/VMN
 /**
  * Substitute URLs, emails, usernames and hashtags with html <a> tags
  * 
  * @param string $text Source text
  * @return string Rendered HTML
  * @deprecated 1.1
  */
 public static function render($text = '')
 {
     $extractor = new Extractor($text);
     return $extractor->linkifyAll()->getHTML();
 }