Facebook Like

Showing posts with label Internet. Show all posts
Showing posts with label Internet. Show all posts

Monday, October 31, 2016

WhatsApp Messenger video calls is made available on Android – Things You should Know about

- No comments
WhatsApp Messenger is backed by social media giant Facebook. Currently, WhatsApp has been rolling out newly updated versions for making their free messaging service better. WhatsApp latest beta update for Android brings the most awaited feature that enables user to make video calls. Here are a few things to notice.

WhatsApp video calls

A few months back, it was rumored that WhatsApp team has been trying to develop the video calling feature for this Messenger. Video calls on WhatsApp was among the best feature for this app. Plus all of this are completely Free worldwide.
WhatsApp Messenger video calls

WhatsApp has more than 1 billion active users, and has been a great messaging apps for Android that has almost everything for the communication over the internet. Says, it’s voice call, send and receive IMs, support for animated GIFs, and now, WhatsApp video calls. Such a compilation of good features in such a great application.

WhatsApp video calling on Android

Earlier this week, many Android news coverage have already reported the WhatsApp newly updated beta version that has a significant feature of video calling.
Android Police has seen the WhatsApp video calls on Android started popping –up for some users in the beta testing program of WhatsApp Messnger.
As for the WhatsApp video calling feature for Windows Phone and iOS, things are pretty much the same. Some users of the app started to have the taste of video calls on their WhatsApp earlier this month.

How to download and install WhatsApp beta version

Notice that WhatsApp video calling feature is now available in the WhatsApp beta updated version. Therefore, thing that you need to do now is either waiting for the stable version of WhatsApp with the video calls coming a little later, or joining the WhatsApp beta testing program.
To become a beta tester, just head over the WhatsApp official website then choose to download and install the WhatsApp Messenger beta from Google Play Store.
You will be able to make both voice and video calls on WhatsApp for Android now. Even though WhatsApp has official advertised for the feature, many users tend to have enjoyed time with WhatsApp video calls already.

Notice on WhatsApp Messenger video calls

To enjoy the WhatsApp video calling feature, one first requirement is your chat partner also have to get the same WhatsApp beta updated version. If not then you won’t be able to make a video call.
So, once you’ve got the WhatsApp updated version with video calling feature, don’t forget to tell your friends that she/he should update WhatsApp Messenger as well.

Thursday, September 1, 2016

The Best Method for Embedding YouTube Videos on your Website

- No comments
It is very easy to embed a YouTube video to your webpages but do you know how much extra weight that embedded YouTube video can add to your web pages? The browser has to download about half a Mb of extra JavaScript files (see screenshot) for rendering the YouTube video player alone. And these files are downloaded even if the visitor never plays the embedded video.
embedded video.

The embedded video not only increases the byte size of your web pages but also the browser has to make multiple HTTP requests to render the video player. This will increase the overall loading time of your page this will effect  the page speed score. The other drawback with the default YouTube embed code is that it is not responsive at all. If people view your website on a mobile phone, the video player is not gonna resize properly for the small screen mobiles.

Embed YouTube Videos without Increasing Page Size

Google+ uses a wise technique for embedding YouTube videos – it will just embeds the thumbnail image of a YouTube video and the actual video player is loaded only when the user manually clicks the thumbnail.
YouTube thumbnail images are only about 15 kB in size so we can reduce the byte size of web pages by 500+ kb. 
The video above is embedded using the same technique (demo).
When a visitor clicks the play button, the thumbnail image is replaced with the standard YouTube video player with autoplay set to 1 so the plays the video instantly. The advantage is that the extra YouTube JavaScript gets loaded only when someone decides to watch the embedded video and not otherwise.

Light and Responsive YouTube Embeds

The standard embed code for YouTube uses the IFRAME tag and the width and height of the video player are hard-coded thus making the player non-responsive.
The new on-demand embed code for YouTube is slightly different. You need not specify the player size as we are now embedding the video responsively. Also, the IFRAME is replaced with a DIV tag and the IFRAME is added to the page only when the visitor clicks the play button.
YouTube Embed Code

Embed YouTube Videos Responsively – Tutorial

Copy-paste the following snippet anywhere in your web page where you would like the YouTube video to appear. Remember to replace VIDEO_ID with the actual ID of the YouTube video.
  1. <div class="youtube-player" data-id="VIDEO_ID"></div>
We will not assign height and width since the video player will automatically occupy the width of the parent while the height is auto-calculated. You can paste multiple DIV blocks with different video IDs if you need to embed multiple videos on the same page.
Next, place the JavaScript anywhere in your web template. It finds all embedded videos on a web page and then replaces the DIV elements with the video thumbnails.
  1. <script>
  2.  
  3. /* Light YouTube Embeds by @labnol */
  4. /* Web: http://labnol.org/?p=27941 */
  5.  
  6. document.addEventListener("DOMContentLoaded",
  7. function() {
  8. var div, n,
  9. v = document.getElementsByClassName("youtube-player");
  10. for (n = 0; n < v.length; n++) {
  11. div = document.createElement("div");
  12. div.setAttribute("data-id", v[n].dataset.id);
  13. div.innerHTML = labnolThumb(v[n].dataset.id);
  14. div.onclick = labnolIframe;
  15. v[n].appendChild(div);
  16. }
  17. });
  18.  
  19. function labnolThumb(id) {
  20. var thumb = '<img src="https://i.ytimg.com/vi/ID/hqdefault.jpg">',
  21. play = '<div class="play"></div>';
  22. return thumb.replace("ID", id) + play;
  23. }
  24.  
  25. function labnolIframe() {
  26. var iframe = document.createElement("iframe");
  27. var embed = "https://www.youtube.com/embed/ID?autoplay=1";
  28. iframe.setAttribute("src", embed.replace("ID", this.dataset.id));
  29. iframe.setAttribute("frameborder", "0");
  30. iframe.setAttribute("allowfullscreen", "1");
  31. this.parentNode.replaceChild(iframe, this);
  32. }
  33.  
  34. </script>
Finally, paste the CSS before the closing head tag of your web template.
This method will reduce the size of your web pages by 500 KB while making yoursite mobile friendly. You may refer to the annotated code to understanding how on-demand embedding works.
  1. <style>
  2. .youtube-player {
  3. position: relative;
  4. padding-bottom: 56.23%;
  5. /* Use 75% for 4:3 videos */
  6. height: 0;
  7. overflow: hidden;
  8. max-width: 100%;
  9. background: #000;
  10. margin: 5px;
  11. }
  12. .youtube-player iframe {
  13. position: absolute;
  14. top: 0;
  15. left: 0;
  16. width: 100%;
  17. height: 100%;
  18. z-index: 100;
  19. background: transparent;
  20. }
  21. .youtube-player img {
  22. bottom: 0;
  23. display: block;
  24. left: 0;
  25. margin: auto;
  26. max-width: 100%;
  27. width: 100%;
  28. position: absolute;
  29. right: 0;
  30. top: 0;
  31. border: none;
  32. height: auto;
  33. cursor: pointer;
  34. -webkit-transition: .4s all;
  35. -moz-transition: .4s all;
  36. transition: .4s all;
  37. }
  38. .youtube-player img:hover {
  39. -webkit-filter: brightness(75%);
  40. }
  41. .youtube-player .play {
  42. height: 72px;
  43. width: 72px;
  44. left: 50%;
  45. top: 50%;
  46. margin-left: -36px;
  47. margin-top: -36px;
  48. position: absolute;
  49. background: url("//i.imgur.com/TxzC70f.png") no-repeat;
  50. cursor: pointer;
  51. }
  52.  
  53. </style>
Please do note that Chrome and Safari browsers on iPhone and Android only allow playback of HTML5 video when initiated by a user interaction. They block embedded media from automatic playback to prevent unsolicited downloads over cellular networks.