diff --git a/rocket-async-css.php b/rocket-async-css.php index aa8ba2a..faf0b8b 100644 --- a/rocket-async-css.php +++ b/rocket-async-css.php @@ -114,3 +114,14 @@ function rocket_async_css_php_vendor_missing() { add_action( 'admin_notices', 'rocket_async_css_php_vendor_missing' ); } } +if ( ! function_exists( 'avada_revslider' ) ): + function avada_revslider( $name ) { + if ( function_exists( 'putRevSlider' ) ) { + ob_start(); + putRevSlider( $name ); + $slider = ob_get_clean(); + echo str_replace( 'tpj(document).ready(function() {', 'tpj(window).load(function() {', $slider ); + + } + } +endif; \ No newline at end of file