Skip to content
Docs
Get RestroPress

Filter

rpress_order_alerts_repeat_interval

Updated
On this page

Filters the seconds between repeats of the new-order alert sound.

The default comes from the order_alerts_repeat_interval setting, falling back to 10 and clamped to 5 through 300. The filtered value is cast to int and passed to the Live Orders script as repeatInterval. It is not clamped again after filtering.

Parameters#

ParameterTypeDescription
$secondsintSeconds between repeats.

Return value#

int. Seconds between repeats.

Example#

add_filter( 'rpress_order_alerts_repeat_interval', 'my_alert_repeat_interval', 10, 1 );
function my_alert_repeat_interval( $seconds ) {
	return 20;
}

Source#

Applied in:

  • includes/features/order-alerts/loader.php (line 193), in RPRESS_Order_Alerts::repeat_interval()

See also#

Was this page helpful?