I have a project in development and I want to use this technique to load a background video element.
This should load into the large white box below the purple nav bar. So far I have added the script to my enqueue-scripts.php file:
wp_enqueue_script( 'video', get_template_directory_uri() . '/assets/js/site/video.js',
array(), '', true );
It seems to be working correctly, as I can see the script video.js is listed in the footer.
The problem is when the script runs, the video element doesn't receive the video source attribute correctly and remains 'undefined'.
Any suggestions?
