This will once again be one of those question there's probably no answer to, but I'll try it anyway.
I created a custom WP plug-in that takes a folder name and outputs all videos inside the folder as images, which when clicked make a video pop-up. The video has custom controls (only play/pause and mute) and I'm using fancybox to make the video pop-up.
Everything works reliably in Opera and Firefox. The video doesn't bother playing in IE9 and, what's most annoying, it sometimes plays in Chrome and sometimes doesn't. (btw Safari won't even pop-up, no idea why).
The plug-in is quite a piece of code, but the end result is a bunch of links with an image inside and a hidden div that contains the links relevant to the current video. Then there's the video container, which is the code for the pop-up. Upon clicking one of the links, the src of the video is swapped for the one that is in the hidden content of the link.
It's quite hard to explain, so please have a look at the code on the website:
http://londoncreativedigital.com/downloads/creativeshowcase/
If you're still reading, here's the plug-in's code
https://github.com/marian-cerny/simple-video-embed
Video playing/pausing is handled in assets/player-controller.js.
I would greatly appreciate any help. I just can't logically explain what can be the reason for this. I tried to debug the JS, but couldn't come up with anything.
For a second I thought that adding a webm video would help, but it doesn't. It behaves the same way, even after adding a webm and removing the mp4 version. (tried on localhost, the online version doesn't have the webm vids).
You hardly ever need to blame your markup or javascript, suppose there is something different than this. I've been it such situations couple of times. All right, here is what I did.
opened video directly in chrome and FF.
open the developer bar on both, and look up the net(network) tab, where you suppose to see headers and other loading information.
in my case here is only one request in FF, and multiply from Chrome and there is canceled or pending only.
tryed the same with ogg clip, it is good in FF though chunked, and bit better in Chrome, part of requests are in pending, part canceled and fiew is good.
What could be wrong here, all right, as I said I do have similar problems in the past, I worked with professional movie maker, who do very good with all that codecs stuff. I just showed him perfectly working mp4 video from the videojs.com and he fixed his somehow by changing encoder or something like this. Unfortunately, I could not connect him how and ask, but probably it gives you some ideas. Please whenever you will be able to solve it, update status over here, I was bit intrigued all that times but had no chance to resolve my curiosity.
Your video was only once worked for me, but I am not sure if it was mp4 or ogg at that point. Also I am on win7 with latest Chrome and FF.
Related
I have a small, very basic 3d game that runs in all browsers. But my issue is that when it runs in Chrome I can see in my console messages that the sounds are "pending" and don't play when they should. The thing is that after some time have passed ALL sounds play at the same time. It doesn't seem to be happening anywhere else, its just in Chrome. I came across this article that someone posted but it did not solve my issue. Just in case I am running Version 43.0.2357.81 m of Chrome and I am using the Sound Manager 2 library (I needed it in order to have sound work with IE 9 and up).
Can anyone offer some suggestions or point me to any more articles that might point me to a solution? Many thanks in advance!
Turn on logging in Chrome (inspect element/console - Preserve log) and see what your code is doing.
Also, you could try enabling/disabling your audio flags just be sure to set them back to default when you are done.
chrome://flags/#disable-encrypted-media
chrome://flags/#disable-prefixed-encrypted-media/
chrome://flags/#try-supported-channel-layouts
chrome://flags/#enable-delay-agnostic-aec
chrome://flags/#disable-delay-agnostic-aec
chrome://flags/#enable-tab-audio-muting
in chrome and see if that makes a difference.
Just shooting from the hip on the information given though, I would imagine that chrome is delaying your audio javascript execution to the end of the page load. Moving the script to the beginning of the page, or using an async could fix this. Here is a good resource for javascript page load issues: http://www.html5rocks.com/en/tutorials/speed/script-loading/
i've been plagued by a problem that seem to started since Youtube's last
layout change this year.
I have for months put up and tried to ignore the freezing that happens
everytime I open a link within youtube such as an channel, an video, the homepage, etc.
I'm using Chrome version 31.0.1650.63 and I have already tested youtube without any
extensions, cookies, cache, etc but it still affects me to this day and maybe some
of you out there.
I searched every where for the solution and couldn't find any anywhere.
I did a bit of digging and testing to see what is the root of the problem and
while i'm no expertise on code or Java...I did found something.
Every time I reload a page on youtube, with it finishing loading up...this happens:
http://i.imgur.com/K9Z3vJ1.png
See that?
The purple-colored rendering, that's the cause of the lag every time I load
up something on youtube!
I notice that it repeats the same thing over and over again for like 5-15 or so
seconds before it starts loading up the thumbnails of the videos.
If you want a closer inspection of the code, here's the raw data from the timeline (that you can load up in chrome's dev timeline window):
Youtube Lag JSON Timeline file
I don't what to do with this problem and I believe it affects
me in Firefox as well but to an lesser extent then chrome.
Do any of you guys know how to resolve this problem?
Honestly I doubt that the youtube devs will fix this problem since they're the ones who caused it in the first place. (Like not being able to subscribe to some people when i'm not even at my sub limit.)
I'm sorry if you don't want to help but I don't know who else to look to besides
the experts that y'all are when it comes to web coding. If anything, I believe a userscript or something similar could help with this but how...I don't know.
I'm new to this and I apologize if the question i'm asking isn't suited for this site.
Still, thanks for reading and if you can...please reply.
That is all and thanks again.
Well I was fiddling around and looking at the source code
with chromes timeline devtools and well...
I found a temporary solution to the problem which seems to have
fixed and ended the freezing on youtube! yay~
But some things don't work with this solution and i'm at
a fault with this issue after some hours trying to figure out
how to stop the problem.
Anyways I used adblock, an extension that I have on Google Chrome, to deal
with this issue and was able to get everything fixed and working!
What I did was, in the custom filters section (check options in your
adblock extension, you should have it.) and added the following then did
some testing to see if it fixed the problem which it did!
Here are the filters I used to fix it!
||s.ytimg.com/yts/jsbin/www-pageframe-*
*www-pageframe-*.js
^^^
Yeah, that's the temporary solution as it fixes the problems but it causes the following...
You can't open the menu which contains links to your playlists, user settings, channel, etc when you click your username or profile
picture on top right of youtube.
The "..." mini-menu that you usually find on the right of a video section (to hide, subscribe, etc.) doesn't appear anymore.
Youtube's quick menu button doesn't work, however the menu is still open but you won't be able to close it. That or it's close and you
won't be able to open it...I guess.
Those are the problems I found with this temporarily solution to the freezing problem.
Yeah...but I hope this helps anyone who's having this problem somewhat well.
But it would be nice if someone has an better solution then mine hehe!
Thanks for reading and if you have a better solution, don't feel afraid to
tell! ^_^
I'll be awaiting other answers, for now...I hope this helps y'all well
in some ways hehe! =D
This certainly isn't javascript, but substituting the normal EasyList in ABP for EasyList without element hiding will fix the issue. There are downsides to this as well but for now seems to be the better solution.
I've searched for many hours trying to find a solution to this problem. I have a HTML5 web page with a background sound file that plays automatically when the page loads, and I'm trying to get a function to run when the sound file finishes playing. I've isolated the code I'm using into a test file to ensure nothing else is causing the problem. The sound plays fine in Firefox (which I'm using to test). From the many solutions I've tried, it seems as though the event attributes in the embed tag simply aren't firing at all.
Here is the test HTML page I'm using (tried putting HTML in here but it wouldn't show up properly, I know it's probably a noob error but I'm in a hurry with this):
Testpage
As you can see the message function works fine, as the "TEST" link indicates when clicked. But the messages for the media events don't appear.
If anyone can help me with this, I'd be most grateful as it's for a time-critical company project. I'd be happy to try alternative solutions to the event attributes, as long as I can get my own Javascript function to run on the sound file reaching its end, I'll be happy!!
Thanks!
Billy
Since you're using HTML5, it would be better to use the <audio> tag rather than <embed>. This works fine in my example:
http://jsfiddle.net/u6dbV/
You can include HTML here, but it has to be marked up as code or it'll get stripped out.
I'm trying to get it so that the clicking the image will play the video underneath. It works absolutely fine in all Mac browsers - here...
http://jsfiddle.net/SparrwHawk/KtbYR/14/
But doesn't work on Windows at all. Maybe it's a Windows security thing, maybe iframes can't have anything underneath? Not sure why this happens. Can anyone offer a work around?
I'm looking to place a still image over a video - the ones that YouTube generate are often blurry, whereas if I place my own over there I can ensure it's of high quality.
Simply add wmode=opaque to the URL params.
Using your code: http://jsfiddle.net/KtbYR/15/
EDIT: See this answer for an explanation
Rather than repeat a long javascript for playing audio, here is the link: webpages.charter.net/jolove/Includes/play_song.js:.
This plays for any desktop browser (Mac or Windows), but not for my iPad.
Here is the calling website: webpages.charter.net/jolove/Escort_Folder/Dedication_Poem_iOS.html
This is really bugging me, so I would definitely appreciate any help on this, any help at all.
John Love
Not sure exactly what your question is, but you can use the HTML5 <audio> tag which is supported by the iPad. Check out http://developer.apple.com/safaridemos/audio.php or just google "HTML5 audio".
I'm almost forced to conclude that iPad will not play audio files.
Here is a very fresh site, where I use
the audio. But, this time, I got a button that says "cannot play audio file". For the sake of completeness, here is the included webpages.charter.net/jolove/Escort_Folder/js/play_song.js