Debug_Bar_Pretty_Output::get_table_start PHP Method

get_table_start() private static method

Generate the table header.
private static get_table_start ( string $col1, string $col2, string | array $class = null, boolean $double_it = false )
$col1 string Label for the first table column.
$col2 string Label for the second table column.
$class string | array One or more CSS classes to add to the table.
$double_it boolean Whether to repeat the table headers as table footer.
        private static function get_table_start($col1, $col2, $class = null, $double_it = false)
        {
            $class_string = '';
            if (is_string($class) && '' !== $class) {
                $class_string = ' class="' . esc_attr($class) . '"';
            }
            $output = '
		<table' . $class_string . '>
			<thead>
			<tr>
				<th>' . esc_html($col1) . '</th>
				<th>' . esc_html($col2) . '</th>
			</tr>
			</thead>';
            if (true === $double_it) {
                $output .= '
				<tfoot>
				<tr>
					<th>' . esc_html($col1) . '</th>
					<th>' . esc_html($col2) . '</th>
				</tr>
				</tfoot>';
            }
            $output .= '
			<tbody>';
            return apply_filters('db_pretty_output_table_header', $output);
        }