Filter
rpress_receipt_page_body_class
On this page
Filters the body CSS class of the in-browser receipt page.
Runs when the receipt is rendered in the browser through the rpress_view_receipt action. The value is passed through sanitize_html_class before output, so only a single class name is kept.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$class | string | Body class. Defaults to 'rpress_receipt_page'. |
Return value#
string. A single CSS class name.
Example#
function my_receipt_body_class( $class ) {
return 'my_receipt_page';
}
add_filter( 'rpress_receipt_page_body_class', 'my_receipt_body_class', 10, 1 );
Notes#
The value is sanitized with sanitize_html_class, so spaces are removed and multiple classes cannot be returned.
Source#
Applied in:
includes/emails/template.php(line 295), inrpress_render_receipt_in_browser()
See also#
Was this page helpful?
