I have this script on php and i need to create table automatcally from that
foreach ( $GetJobResult->Components->Component as $component_index => $component ) {
$quote_title = ($component_index + 1) . ') ' . $component->Title . "-Machine :\r\n";
if (isset ( $component->Paper->Family )) {
if (isset ( $component->Paper->Type ) && isset ( $component->Paper->Color )) {
if ($component->Ink->FrontColors == '0') {
$quote_impression = "sans impression\r\n";
}
$getPaperInfoResult = $ws->getPaperInfo ( $component->Paper->Family, $component->Paper->Type );
foreach ( $getPaperInfoResult->PapFamType as $paper_index => $paperinfo ) {
if (($paperinfo->Ccoul == $component->Paper->Color) && ($paperinfo->Gramm == $component->Paper->Weight)) {
$quote_support = $paperinfo->Lfam . ' - ' . $paperinfo->Lcoul . ' - ' . $paperinfo->Gramm . ' g/m2' . "\n";
$quote_impression = $component->Ink->FrontColors . ' Couleur(s) ( ' . $component->Ink->FrontColorDesc . ') au recto / ' . $component->Ink->BackColors . ' Couleur(s)' . ' ( ' . $component->Ink->BackColorDesc . ' ) ' . "\n";
break;
}
// $quote_desc[]= $getPaperInfoResult->PapFamType [$component_index + 1]->Lfam . ' - ' . $getPaperInfoResult->PapFamType [$component_index + 1]->Lcoul . ' - ' . $getPaperInfoResult->PapFamType [$component_index + 1]->Gramm . ' g/m2' . "\n";
}
}
$row++; $col++;
$tbl = $p->add_table_cell($tbl, $col, $row, $quote_title, $opttitrecontact);
$imp_text_element1.=$quote_title."-Support : ".$quote_support."-Impression : ".$quote_impression;
}
}
It's done table in each cell the data and skip the one cell on put the data so i need just table contains the data how can i do that.