ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
39dropdown.php File Reference

Go to the source code of this file.

Namespaces

 PHPExcel
 

Functions

 transpose ($value)
 

Variables

const EOL (PHP_SAPI == 'cli') ? PHP_EOL : '<br />'
 
Create new PHPExcel object
 
 $objPHPExcel = new PHPExcel()
 
Set document properties
 
 $continentColumn = 'D'
 
 $column = 'F'
 
 $objValidation
 
Write to Excel2007 format
 
 $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007')
 
File written to
 
Peak memory usage
 
Peak memory memory_get_peak_usage(true)/1024/1024) MB
 
Done writing files
 

Function Documentation

◆ transpose()

transpose (   $value) -> setCreator("PHPOffice") ->setLastModifiedBy("PHPOffice") ->setTitle("PHPExcel Test Document") ->setSubject("PHPExcel Test Document") ->setDescription("Test document for PHPExcel, generated using PHP classes.") ->setKeywords("Office PHPExcel php") ->setCategory("Test result file")

Definition at line 56 of file 39dropdown.php.

References array.

56  {
57  return array($value);
58 }
59 
60 // Add some data
61 $continentColumn = 'D';
62 $column = 'F';
63 
64 // Set data for dropdowns
65 foreach(glob('./data/continents/*') as $key => $filename) {
66  $continent = pathinfo($filename, PATHINFO_FILENAME);
67  echo "Loading $continent", EOL;
68  $continent = str_replace(' ','_',$continent);
69  $countries = file($filename, FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES);
70  $countryCount = count($countries);
71 
72  // Transpose $countries from a row to a column array
73  $countries = array_map('transpose', $countries);
74  $objPHPExcel->getActiveSheet()
75  ->fromArray($countries, null, $column . '1');
76  $objPHPExcel->addNamedRange(
78  $continent,
79  $objPHPExcel->getActiveSheet(), $column . '1:' . $column . $countryCount
80  )
81  );
82  $objPHPExcel->getActiveSheet()
83  ->getColumnDimension($column)
84  ->setVisible(false);
85 
86  $objPHPExcel->getActiveSheet()
87  ->setCellValue($continentColumn . ($key+1), $continent);
88 
89  ++$column;
90 }
const EOL
Definition: 39dropdown.php:34
$objPHPExcel
Definition: 39dropdown.php:42
$column
Definition: 39dropdown.php:62
$continentColumn
Definition: 39dropdown.php:61
Reload workbook from saved file
Create styles array
The data for the language used.
$key
Definition: croninfo.php:18

Variable Documentation

◆ $column

$column = 'F'

Definition at line 62 of file 39dropdown.php.

Referenced by ilQueryUtils\__construct(), ilStudyProgrammeIndividualPlanTableGUI\__construct(), ilTermsOfServiceAcceptanceHistoryTableGUI\__construct(), ilStudyProgrammeMembersTableGUI\__construct(), MDB2_Result_Common\_assignBindColumns(), PHPExcel_Reader_HTML\_flushCell(), MDB2_Result_oci8\_getColumnNames(), MDB2_Result_pgsql\_getColumnNames(), MDB2_Result_mysql\_getColumnNames(), MDB2_Result_mysqli\_getColumnNames(), ilMailBoxQuery\_getMailBoxListData(), PHPExcel_Reader_Excel5\_includeCellRangeFiltered(), PHPExcel_Reader_HTML\_processDomElement(), PHPExcel_Reader_Excel5\_readBIFF8CellAddress(), PHPExcel_Reader_Excel5\_readBIFF8CellAddressB(), PHPExcel_Reader_Excel5\_readBoolErr(), PHPExcel_Reader_Excel5\_readFormula(), PHPExcel_Reader_Excel5\_readLabel(), PHPExcel_Reader_Excel5\_readLabelSst(), PHPExcel_Reader_Excel5\_readNumber(), PHPExcel_Reader_Excel5\_readRk(), PHPExcel_Reader_HTML\_setTableStartColumn(), PHPExcel_Writer_Excel2007_Worksheet\_writeAutoFilter(), PHPExcel_Writer_OpenDocument_Content\_writeCells(), PHPExcel_Writer_Excel5_Worksheet\_writePanes(), PHPExcel_Writer_Excel2007_Comments\_writeVMLComment(), PHPExcel_Cell\absoluteCoordinate(), MDB2_Result_Common\bindColumn(), PHPExcel_Writer_HTML\buildCSS(), ilObjBookingPoolGUI\buildDatesBySchedule(), PHPExcel_Calculation_LookupRef\CELL_ADDRESS(), PHPExcel_Writer_Excel5_Escher\close(), PHPExcel_Writer_Excel5_Worksheet\close(), TCPDF\closeHTMLTagHandler(), TCPDF\drawHTMLTagBorder(), ilSessionStatisticsGUI\exportCSV(), PHPExcel_Cell\extractAllCellReferencesInRange(), MDB2_Result_Common\fetchCol(), ilTestQuestionsTableGUI\fillHeader(), ilQuestionBrowserTableGUI\fillHeader(), ilTable2GUI\fillHeader(), ilTable2GUI\fillHeaderCSV(), ilTable2GUI\fillHeaderExcel(), ilStudyProgrammeIndividualPlanTableGUI\fillRow(), ilMailTemplateTableGUI\fillRow(), ilStudyProgrammeMembersTableGUI\fillRow(), ilTermsOfServiceTableGUI\fillRow(), ilMailTemplateTableGUI\formatCellValue(), ilTermsOfServiceTableGUI\formatCellValue(), ilTermsOfServiceAgreementByLanguageTableGUI\formatCellValue(), ilTermsOfServiceAcceptanceHistoryTableGUI\formatCellValue(), ilMailAttachmentTableGUI\formatValue(), PHPExcel_Writer_HTML\generateSheetData(), PHPExcel_CachedObjectStorage_CacheBase\getCurrentColumn(), PHPExcel_CachedObjectStorage_CacheBase\getCurrentRow(), PHPExcel_Worksheet\getHighestDataRow(), PHPExcel_CachedObjectStorage_CacheBase\getHighestRow(), PHPExcel_Worksheet\getHighestRow(), ilTrMatrixTableGUI\getItems(), ilTrQuery\getObjectAccessStatistics(), ilTrQuery\getObjectLPStatistics(), ilTrSummaryTableGUI\getSelectableColumns(), PHPExcel_CachedObjectStorage_CacheBase\getSortedCellList(), ilDBPdoReverse\getTableFieldDefinition(), MDB2_Driver_Reverse_oci8\getTableFieldDefinition(), MDB2_Driver_Reverse_pgsql\getTableFieldDefinition(), MDB2_Driver_Reverse_mysql\getTableFieldDefinition(), MDB2_Driver_Reverse_mysqli\getTableFieldDefinition(), SurveyMatrixQuestion\hasNeutralColumn(), ilDclContentImporter\import(), SurveyMatrixQuestion\importResponses(), ilOrgUnitTypeTableGUI\initColumns(), ilOrgUnitPositionTableGUI\initColumns(), ilStudyProgrammeTypeTableGUI\initColumns(), ilTrObjectUsersPropsTableGUI\initFilter(), PHPExcel_ReferenceHelper\insertNewBefore(), ilTermsOfServiceTableGUI\isColumnVisible(), ilMySQLQueryUtils\like(), ilPostgresQueryUtils\like(), ilDBPdo\like(), PHPExcel_Reader_Excel2007\load(), PHPExcel_Reader_Excel5\load(), PHPExcel_Reader_SYLK\loadIntoExisting(), PHPExcel_Reader_Gnumeric\loadIntoExisting(), PHPExcel_Reader_HTML\loadIntoExisting(), PHPExcel_Calculation_MathTrig\MDETERM(), PHPExcel_Calculation_MathTrig\MINVERSE(), TCPDF\MultiCell(), ilMailAttachmentTableGUI\numericOrdering(), ilTestExportTableGUI\numericOrdering(), ilTermsOfServiceAcceptanceHistoryTableGUI\numericOrdering(), ilTermsOfServiceAgreementByLanguageTableGUI\numericOrdering(), ilMailSearchCoursesTableGUI\numericOrdering(), ilQuestionPoolPrintViewTableGUI\numericOrdering(), ilQuestionBrowserTableGUI\numericOrdering(), PHPExcel_Shared_Excel5\oneAnchor2twoAnchor(), PHPExcel_CachedObjectStorage_CacheBase\removeColumn(), PHPExcel_Worksheet_RowCellIterator\seek(), PHPExcel_Worksheet_ColumnIterator\seek(), PHPExcel_Worksheet_AutoFilter\setColumn(), MDB2_Driver_Reverse_oci8\tableInfo(), PHPExcel_Worksheet_AutoFilter\testColumnInRange(), WorksheetColumnTest\testGetCellIterator(), WorksheetColumnTest\testInstantiateColumnDefault(), WorksheetColumnTest\testInstantiateColumnSpecified(), ColumnIteratorTest\testIteratorFullRange(), ColumnIteratorTest\testIteratorStartEndRange(), PHPExcel_Calculation_LookupRef\TRANSPOSE(), PHPExcel_ReferenceHelper\updateFormulaReferences(), and ilWikiStat\writeData().

◆ $continentColumn

$continentColumn = 'D'

Definition at line 61 of file 39dropdown.php.

◆ $objPHPExcel

$objPHPExcel = new PHPExcel()

Definition at line 42 of file 39dropdown.php.

◆ $objValidation

$objValidation
Initial value:
= $objPHPExcel->getActiveSheet()
->getCell('B1')
->getDataValidation()
$objPHPExcel
Definition: 39dropdown.php:42

Definition at line 119 of file 39dropdown.php.

◆ $objWriter

$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007')

Definition at line 166 of file 39dropdown.php.

◆ EOL

getcwd () EOL (PHP_SAPI == 'cli') ? PHP_EOL : '<br />'

Definition at line 34 of file 39dropdown.php.

◆ files

Done writing files

Definition at line 174 of file 39dropdown.php.

◆ format

Write to Excel2007 format

Definition at line 165 of file 39dropdown.php.

◆ MB

Peak memory memory_get_peak_usage (true)/1024/1024) MB

Definition at line 171 of file 39dropdown.php.

◆ object

Create new PHPExcel object

Definition at line 37 of file 39dropdown.php.

◆ properties

Set document properties

Definition at line 45 of file 39dropdown.php.

◆ to

File written to

Definition at line 168 of file 39dropdown.php.

◆ usage

Peak memory usage

Definition at line 171 of file 39dropdown.php.