phylotree; if ($phylotree->analysis_id) { // the $headers array is an array of fields to use as the colum headers. // additional documentation can be found here // https://api.drupal.org/api/drupal/includes%21theme.inc/function/theme_table/7 $header = [ 'Name', 'Description', [ 'data' => 'Metadata', 'width' => '50%', ], ]; // the $rows array contains an array of rows where each row is an array // of values for each column of the table in that row. Additional documentation // can be found here: // https://api.drupal.org/api/drupal/includes%21theme.inc/function/theme_table/7 $rows = []; $analysis = $phylotree->analysis_id; if ($analysis) { $analysis = chado_expand_var($analysis, 'field', 'analysis.description'); // Source row $source = ''; if ($analysis->sourceuri) { $source = "sourceuri\">$analysis->sourcename"; } else { $source = $analysis->sourcename; } if ($analysis->sourceversion) { $source = " (" . $analysis->sourceversion . ")"; } $software = $analysis->program; if ($analysis->programversion != 'n/a') { $software .= " (" . $analysis->programversion . ")"; } if ($analysis->algorithm) { $software .= ". " . $analysis->algorithm; } $date = preg_replace("/^(\d+-\d+-\d+) .*/", "$1", $analysis->timeexecuted); $metadata = "