Skip to content

Instantly share code, notes, and snippets.

@hbrandl
Last active December 27, 2015 03:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hbrandl/7258288 to your computer and use it in GitHub Desktop.
Save hbrandl/7258288 to your computer and use it in GitHub Desktop.
JS that fixes the YouTube-API V2 Browser Upload for Firefox < 26
<script type="text/javascript">
//fixes issue https://code.google.com/p/gdata-issues/issues/detail?id=4919 by switching to http for Firefox < 26
//you need jQuery < 1.9 or the jQuery.migrate plugin - http://api.jquery.com/jQuery.browser/
//add this code after the form
if ($.browser.mozilla && $.browser.version < 26){
$('form').attr('action', 'THE_URL_WITH_HTTP_INSTEAD_OF_HTTPS');
}
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment