Skip to content

Instantly share code, notes, and snippets.

@mifix
Created September 17, 2009 14:40

Revisions

  1. mifix created this gist Sep 17, 2009.
    23 changes: 23 additions & 0 deletions gistfile1.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,23 @@
    /**
    * makePlain2ColTable
    *
    * Tabelle ohne Rahmen mit 2 Spalten
    *
    * @param array arr_data Assoziativer Array mit Daten f�r TabSpalten
    * @param array col_param Breite, H�he & Ausrichting von Spalte 1 und 2
    * @param array tab_pos Postition der Tabelle
    * @returns yPostition
    **/
    function makePlain2ColTable($arr_data, $col_param, $tab_pos) {
    $this->SetY($tab_pos[1]);
    foreach($arr_data as $key => $value)
    {
    $this->SetX($tab_pos[0]);
    parent::setFont('', 'B');
    $this->Cell($col_param[0], $col_param[1], $key, 0, 0, $col_param[2]);
    parent::setFont('', '');
    $this->Cell($col_param[3], $col_param[4], $value, 0, 0, $col_param[5]);
    $this->Ln();
    }
    return $this->getY();
    } // end of member function makePlain2ColTable