PHPRtfLite_Element_Hyperlink::setHyperlink PHP Метод

    public function setHyperlink($hyperlink)
    {
        $this->_hyperlink = $hyperlink;
    }

Usage Example

Пример #1
0
 /**
  * tests render().
  */
 public function testRender()
 {
     $hyperlink = new PHPRtfLite_Element_Hyperlink($this->_rtf, 'My link text!');
     $hyperlink->setHyperlink('http://www.phprtf.com/');
     $hyperlink->render();
     $expected = '{\\field {\\*\\fldinst {HYPERLINK "http://www.phprtf.com/"}}{\\fldrslt {My link text!}}}';
     $this->assertEquals($expected, trim($this->_rtf->getWriter()->getContent()));
 }
All Usage Examples Of PHPRtfLite_Element_Hyperlink::setHyperlink