You are here

private function PHPExcel_Writer_Excel2007_Rels::_writeRelationship in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php \PHPExcel_Writer_Excel2007_Rels::_writeRelationship()

* Write Override content type * *

Parameters

PHPExcel_Shared_XMLWriter $objWriter XML Writer: * @param int $pId Relationship ID. rId will be prepended! * @param string $pType Relationship type * @param string $pTarget Relationship target * @param string $pTargetMode Relationship target mode * @throws PHPExcel_Writer_Exception

5 calls to PHPExcel_Writer_Excel2007_Rels::_writeRelationship()
PHPExcel_Writer_Excel2007_Rels::writeDrawingRelationships in vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php
* Write drawing relationships to XML format * *
PHPExcel_Writer_Excel2007_Rels::writeHeaderFooterDrawingRelationships in vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php
* Write header/footer drawing relationships to XML format * *
PHPExcel_Writer_Excel2007_Rels::writeRelationships in vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php
* Write relationships to XML format * *
PHPExcel_Writer_Excel2007_Rels::writeWorkbookRelationships in vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php
* Write workbook relationships to XML format * *
PHPExcel_Writer_Excel2007_Rels::writeWorksheetRelationships in vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php
* Write worksheet relationships to XML format * * Numbering is as follows: * rId1 - Drawings * rId_hyperlink_x - Hyperlinks * *

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Rels.php, line 419

Class

PHPExcel_Writer_Excel2007_Rels
PHPExcel_Writer_Excel2007_Rels

Code

private function _writeRelationship(PHPExcel_Shared_XMLWriter $objWriter = null, $pId = 1, $pType = '', $pTarget = '', $pTargetMode = '') {
  if ($pType != '' && $pTarget != '') {

    // Write relationship
    $objWriter
      ->startElement('Relationship');
    $objWriter
      ->writeAttribute('Id', 'rId' . $pId);
    $objWriter
      ->writeAttribute('Type', $pType);
    $objWriter
      ->writeAttribute('Target', $pTarget);
    if ($pTargetMode != '') {
      $objWriter
        ->writeAttribute('TargetMode', $pTargetMode);
    }
    $objWriter
      ->endElement();
  }
  else {
    throw new PHPExcel_Writer_Exception("Invalid parameters passed.");
  }
}