Resizing element to parent div

1) CSS only Demo HTML <div class=”wrapper”> <video class=”videoInsert”> <source src=”http://www.w3schools.com/html/movie.mp4″ type=”video/mp4″> <source src=”movie.ogg” type=”video/ogg”> Your browser does not support the video tag. </video> </div> css .videoInsert { position: absolute; right: 0; bottom: 0; min-width: 100%; min-height: 100%; width: auto; height: auto; z-index: -100; background-size: cover; overflow: hidden; } 2) jQuery Demo HTML <div id=”video-viewport”> … Read more

Unknown encoder ‘libfaac’

FFmpeg removed libfaac support in 2016 because the other AAC encoders are better. Use a different encoder. Native FFmpeg AAC Encoder (-c:a aac) Use the native, built-in FFmpeg AAC encoder: ffmpeg -i input.wav -c:a aac output.m4a Included by default in all ffmpeg versions. Has many features, fairly good quality, supports the most channel layouts and … Read more

ffmpeg convert mov file to mp4 for HTML5 video tag IE9

For ffmpeg: ffmpeg -i {input}.mov -vcodec h264 -acodec aac -strict -2 {output}.mp4 You may also add the -q:v/-q:a parameter to specify the quality of the video. You may also use HandBrake which is a simpler encoder than ffmpeg. For HandBrake: handbrakecli -i {input}.mov -e x264 -E facc -o {output}.mp4   EDIT: I found the solution! … Read more

Clicking HTML 5 Video element to play, pause video, breaks play button

The simplest form is to use the onclick listener: <video height=”auto” controls=”controls” preload=”none” onclick=”this.play()”> <source type=”video/mp4″ src=”vid.mp4″> </video> No jQuery or complicated Javascript code needed. Play/Pause can be done with onclick=”this.paused ? this.play() : this.pause();”. To keep it from clashing with the video controls on some browsers, call preventDefault on the click event: onclick=”this.paused ? … Read more

Generate preview image from Video file?

Solution #1 (Older) (not recommended) Firstly install ffmpeg-php project (http://ffmpeg-php.sourceforge.net/) And then you can use of this simple code: <?php $frame = 10; $movie=”test.mp4″; $thumbnail=”thumbnail.png”; $mov = new ffmpeg_movie($movie); $frame = $mov->getFrame($frame); if ($frame) { $gd_image = $frame->toGDImage(); if ($gd_image) { imagepng($gd_image, $thumbnail); imagedestroy($gd_image); echo ‘<img src=”‘.$thumbnail.'”>’; } } ?> Description: This project use binary … Read more

Disable fullscreen iphone video

In iOS 10+ Apple finally enabled the attribute playsinline in all browsers on iOS 10, so this will work seamlessly: <video src=”https://stackoverflow.com/questions/19521667/file.mp4″ playsinline> In iOS 8 and iOS 9 You can work around this issue by simulating the playback by skimming the video instead of actually .play()‘ing it. In short, use iphone-inline-video, it takes care … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)