31 lines
685 B
PHP
31 lines
685 B
PHP
<?php
|
|
/**
|
|
* Animated background from trivelta.
|
|
*/
|
|
|
|
if ( ! defined( 'ABSPATH' ) ) {
|
|
exit;
|
|
}
|
|
|
|
function alcastromol_animated_background_assets() {
|
|
$dir = get_template_directory() . '/parts/animated-background';
|
|
$uri = get_template_directory_uri() . '/parts/animated-background';
|
|
|
|
wp_enqueue_style(
|
|
'alcastromol-animated-background',
|
|
$uri . '/animated-background.css',
|
|
array(),
|
|
filemtime( $dir . '/animated-background.css' )
|
|
);
|
|
|
|
wp_enqueue_script(
|
|
'alcastromol-animated-background',
|
|
$uri . '/animated-background.js',
|
|
array(),
|
|
filemtime( $dir . '/animated-background.js' ),
|
|
true
|
|
);
|
|
}
|
|
|
|
add_action( 'wp_enqueue_scripts', 'alcastromol_animated_background_assets' );
|