 
	
		
		
		
		
			
- 
		AuthorPosts
- 
		
			
				
October 9, 2021 at 4:57 pm #1324222Hi, In an effort to squeeze the last few ms loading time improvement out of my website, I have a question about the standard WP mediaplayer scripts and css. I was experimenting with deregistering the script and css for that WP included mediaplayer stuff (/wp-includes/js/mediaelement/) like this in my child theme functions.php: function deregister_media_elements(){ wp_deregister_script('wp-mediaelement'); wp_deregister_style('wp-mediaelement'); } add_action('wp_enqueue_scripts','deregister_media_elements');As far as I can tell from my experiments, this change does not affect any video capability within Enfold, not even including videos in a post the standard WP way… :-) Am I right in this and can I do this without harm when using Enfold, or am I missing something? Thanks in advance for clarifying, 
 RobOctober 11, 2021 at 5:08 am #1324356Hey Rob, Thank you for the inquiry. You can actually toggle the script in the Enfold > Performance > Self hosted videos and audio features (WP-Mediaelement scripts) settings. The script is used for html5 videos and audios, so you can safely deregister the script if you are not using any of those. However, some plugins automatically requires the script, which might cause an error or produce a warning if the script is deregistered. Best regards, 
 IsmaelOctober 11, 2021 at 7:14 am #1324366Hi Ismael, Thanks for the confirmation and the info, good to know. I already had that toggle set, but the player script + css continued to load on translated pages, I will take that up with the plugin developer too. That’s why I wanted to deregister it completely. Have a good day! 
 Rob- 
		This reply was modified 4 years ago by rob2701. 
 October 11, 2021 at 11:13 am #1324390Hi Rob, Thanks for the update. Please let us know if you should need any further help on the topic or if we can close it. Best regards, 
 RikardOctober 11, 2021 at 11:17 am #1324391Hi Rikard, Thanks for the help, you can close it. Rob 
- 
		This reply was modified 4 years ago by 
- 
		AuthorPosts
- The topic ‘Question about WP media-elements and Enfold’ is closed to new replies.
