Drupal investigation

border-custom2.phpt 711B

12345678910111213141516171819202122232425262728
  1. --TEST--
  2. Border: new custom mode, alternative style
  3. --FILE--
  4. <?php
  5. error_reporting(E_ALL | E_NOTICE);
  6. if (file_exists(dirname(__FILE__) . '/../Table.php')) {
  7. require_once dirname(__FILE__) . '/../Table.php';
  8. } else {
  9. require_once 'Console/Table.php';
  10. }
  11. $table = new Console_Table(
  12. CONSOLE_TABLE_ALIGN_LEFT,
  13. array('horizontal' => '=', 'vertical' => '', 'intersection' => '')
  14. );
  15. $table->setHeaders(array('City', 'Mayor'));
  16. $table->addRow(array('Leipzig', 'Major Tom'));
  17. $table->addRow(array('New York', 'Towerhouse'));
  18. echo $table->getTable();
  19. ?>
  20. --EXPECT--
  21. ======================
  22. City Mayor
  23. ======================
  24. Leipzig Major Tom
  25. New York Towerhouse
  26. ======================