Automattic\WooCommerce\EmailEditor\Integrations\Utils
Table_Wrapper_Helper::render_table_cell
Render a table cell.
Method of the class: Table_Wrapper_Helper{}
No Hooks.
Returns
String. The generated table cell HTML.
Usage
$result = Table_Wrapper_Helper::render_table_cell( $content, $cell_attrs ): string;
- $content(string) (required)
- The content to wrap.
- $cell_attrs(array)
- Cell attributes.
Default:array()
Table_Wrapper_Helper::render_table_cell() Table Wrapper Helper::render table cell code WC 10.8.1
public static function render_table_cell(
string $content,
array $cell_attrs = array()
): string {
$cell_attr_string = self::build_attributes_string( $cell_attrs );
return sprintf(
'<td%1$s>%2$s</td>',
$cell_attr_string ? ' ' . $cell_attr_string : '',
$content
);
}