Skip to content

Instantly share code, notes, and snippets.

@johnsardine
Created February 17, 2016 11:23
Show Gist options
  • Save johnsardine/87df9cc8b1f0744fb315 to your computer and use it in GitHub Desktop.
Save johnsardine/87df9cc8b1f0744fb315 to your computer and use it in GitHub Desktop.
var videoPlayerEmbed = jQuery('#playerID'); // Get player embed
var videoURL = videoPlayerEmbed.prop('src'); // Get current src
videoURL = videoURL.replace("&autoplay=1", ""); // Remove autoplay if exists
videoPlayerEmbed.prop('src',''); // Remove src to reset
videoPlayerEmbed.prop('src',videoURL); // Add src again, resetting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment