How to remove Logo and other attributes from YouTube Video?

logo-remove-youtube-wordpress

Sometimes we want to hide the video title, YouTube logo, and other YouTube attributes of the video from the user for preventing direct access to the video on the YouTube Site. We can hide some default attributes like related videos, copy links,s, etc. by passing the attribute values in the YouTube link. But we can hide the other attributes like the YouTube logo, title, share option by using 3rd party plugins.

Below we are discussing regarding one third party plugin which helps you to remove Logo and other attributes from YouTube.

Source : https://github.com/pupunzi/jquery.mb.YTPlayer/wiki

For hiding this attributes you need to include two files of third party plugin that is one CSS and one JS file. If the jQuery library was not linked before then it needs to be linked for working the plugin correctly.

<link href="css/YTPlayer.css" media="all" rel="stylesheet" type="text/css">

<script src="http://ajax.googleapis.com/ajax/libs/jquery/3.0.0/jquery.min.js"></script>
<script src="inc/jquery.mb.YTPlayer.js"></script>

Predefined JQuery Method Call

<script>
    jQuery(function(){
      jQuery("#[playerID]").YTPlayer();
    });
</script>

HTML constructor

<div id="bgndVideo" class="player" data-property="{videoURL:'http://youtu.be/BsekcY04xvQ',containment:'body',autoPlay:true, mute:true, startAt:0, opacity:1}">My video</div>

Other Options

data-property is an attribute of the TAG where you can pass the options of the player as an Object. Any of the below parameters can also be passed as option within the initialize function. The one defined as an attribute of the TAG wins.

  • mute: true (boolean) mute the audio;
  • showControls: true (boolean) show or hide the player controls;
  • useOnMobile: true (boolean) Define if the player should render on mobile devices.
  • mobileFallbackImage: absolute/path/to/image (string) The path to the fallback image in case of background video on mobile devices and the “useOnMobile” option is set to false;
  • coverImage: absolute/path/to/image (string) The path to the image used as background for the player if autoplay is set to false; if not set the player will show the first frame;
  • ratio: ‘4/3’, ‘16/9’ or ‘auto’ (string) to set the aspect ratio of the movie; if ‘auto’ the aspect ratio will be retreived form the getDataFromFeed method.
  • The quality parameter has been deprecated on the YT API and never more used. YouTube adjusts the quality of your video stream based on your viewing conditions.
  • opacity: 0 to 1 (number) define the opacity of the video.
  • containment: (string) the CSS selector of the DOM element where you want the video background; if not specified it takes the “body”; if set to “self” the player will be instanced on that element.
  • optimizeDisplay: true (boolean) will fit the video size into the window size optimizing the view.
  • loop: false (boolean) or a number rapresenting how many times the video should loops once ended.
  • vol: 1 to 100 (number) set the volume level of the video.
  • startAt: 20 (number) Set the seconds the video should start at.
  • stopAt: 20 (number) Set the seconds the video should stop at. If 0 is ignored.
  • remember_last_time: true (boolean) if true living the page and getting back the video will start where it was left.
  • autoPlay: true (boolean) or false play the video once ready; with the latest vendor policy the autoplay works only if the mute option is set to true otherwise the video will start with the first click/touch user interaction with the page.
  • showYTLogo: true (boolean) Show or hide the YT logo and the link to the original video URL.
  • addRaster: false (boolean) Show or hide a raster image over the video.
  • mask: ‘path/to/mask’ or object {0:‘path/to/mask1’, 20:‘path/to/mask2’, …} or false. From version 3.0. Add a mask to the player or a map of masks for each time specified.
  • realfullscreen: true (boolean) activate the new HTML5 full screen behavior.
  • stopMovieOnBlur: true (boolean) activate the pause behavior when the window loose focus.
  • playOnlyIfVisible: false (boolean) activate the pause behavior when the player is out of screen.
  • gaTrack: true (boolean) activate the Google Analytics event tracker for that player.
  • anchor: ‘center,center’ (string) From version 3.0.3. Define how the video will behave once the window is resized; possible value are: ‘top,bottom,left,right,center’; it accept a pair of value comma separated (ex: ‘top,right’ or ‘bottom,left’).
  • showAnnotations: false (boolean) Define if the player should or not show annotations.
  • cc_load_policy: false (boolean) Define if the player should or not show subtitles.
  • abundance: 0.2 (float) define the percentage of the size to add as abundance.
  • onReady: (function) You can pass a function that will be fired once the player is ready; it will pass the YTPlayer object as parameter.
  • onError: (function) You can pass a function that will be fired if there’s an error loading the video; it will pass the YTPlayer object and the error as the parameter.

Other functionalities of this plugin can be found on Source link : https://github.com/pupunzi/jquery.mb.YTPlayer/wiki

If any doubt appears in your mind regarding the article “remove Logo and other attributes from YouTube” do comment us. Thank You