Exemplo n.º 1
0
 /**
  * Write links to external directory names such as 'c:\foo.xls',
  * c:\foo.xls#Sheet1!A1', '../../foo.xls'. and '../../foo.xls#Sheet1!A1'.
  *
  * @param Range $range Cell range
  * @param string $url    URL string
  * @param string $label    Alternative label
  * @param mixed $format The cell format
  */
 protected function writeUrlExternal(Range $range, $url, $label, $format = null)
 {
     // Strip URL type and change Unix dir separator to Dos style (if needed)
     $url = preg_replace('/^external:/', '', $url);
     $url = preg_replace('/\\//', "\\", $url);
     $this->writeUrlLabel($range->getStartCell(), $url, $label, $format);
     $this->appendRecord('HyperlinkExternal', array($range, $url));
 }