/** * Add image footer by URL */ public function testAddImageFooterByUrl() { $oCell = new Cell('footer', 1); $element = $oCell->addImage('https://assets.mozillalabs.com/Brands-Logos/Thunderbird/logo-only/thunderbird_logo-only_RGB.png'); $this->assertCount(1, $oCell->getElements()); $this->assertInstanceOf('PhpOffice\\PhpWord\\Element\\Image', $element); }
/** * Add image section by URL */ public function testAddImageSectionByUrl() { $oCell = new Cell(); $element = $oCell->addImage('http://php.net/images/logos/php-med-trans-light.gif'); $this->assertCount(1, $oCell->getElements()); $this->assertInstanceOf('PhpOffice\\PhpWord\\Element\\Image', $element); }