Behat Test for media files - symfony

I want to test a video file. This video file appears a modal dialog. How can I test the functionality?
I could look for html video-tag like this:
$this->getSession()->getPage()->find("html", 'video');
but i want to test functionality of video playing.
Thanks.

I most cases when a video is added into a page it will be included in an iframe.
What you could test is that the modal is opened and contains an iframe with the video.
You could try to play the video, which will not help since you would need to use some external api's to see if the video is really playing, but this is an overkill.

Related

Alternative of Screencast.com Video Embedder video plugin in Wordpress

I want to use videos from www.screencast.com in WordPress want to to show multiple links for videos in single page and when I click on a link it should the video in popup form.
I tried this "Screencast.com Video Embedder " but this is not opening videos in popup from.
Please Help.
Just take the embed code from the screencast.com share option and paste that into your post's html. Then go back to the visual mode and adjust the dimensions if necessary to fit your screen (600 px or whatever).
Better yet, when you look at the Screencast site, instead of grabbing the “Embed On Your Page” code, simply look above at the “Share URL.” This is the content you’ll need to add to the Screencast Short Code. Make sure you grab “http:……../” and everything. So your shortcode should look like this;
[screencast url="http:www.screeencast.com/123XYZabc" width="xxx" height="yyy"]
The next plugin you'll need doesn't get rave reviews, but I do know some people who've used this successfully. I know it's old, but apparently still works. Popup Video Generator. And here's an example of how to use it properly.

How to Over ride youtube external style?

I'm working on a website and i use a wordpress plug-in that embeds youtube videos.
Now it has this great option to show only an image of the video and load the video only if you press the video so the page won't take a lot of time to load.
The problem is that in that mode it takes that video photo from youtube and it also takes a big, red, play button image that is ugly as hell :)
Now that button's css is coming from some external link (http://s.ytimg.com/yts/cssbin/www-embed-vflSBO3VV.css) and i don't know how to over ride it.
Any suggestions?
That is the site i'm working on btw - http://www.lab.gezerweb.com/ClipPress/
Thanks.
I believe you're talking about an embed that uses controls=2, correct? (See https://developers.google.com/youtube/player_parameters#controls)
If so, then no, there's no way to override the default play button in the cued state.

Auto Play Youtube Embedded Video without editing the embedding code

I am working on a music site for a client (in Wordpress), and they would like the 'Featured Youtube video' that will display on the homepage to autoplay when the page loads. I'm looking for a solution that wouldn't require client to edit the code when they paste the embedding code for Youtube. Is there a way I can hard code this to my template files?
Most solutions out there are about editing the code to enable autoplay. Any ideas?
You could manipulate the html using jQuery, you would target the element and insert the html required to autoplay, this way it can be inserted each time the page loads.
W3Schools and this JQuery link should get you going.

Play audio online in ASP.Net website

i need to play audio online in asp.net website
My requirement is
users will be able to browser the audio file using file upload control and two button will be displayed 'Play' and 'Stop'.
site should have the capability to play audio file in any format.
Please share any links or code to achieve this.
Thanks!
Look into these links. They may help.
http://forums.asp.net/t/1303198.aspx
http://www.dotnetspider.com/resources/5014-Play-Audio-File-Wav.aspx
http://www.dotnetspider.com/resources/22231-Play-audio-files-asp-net.aspx
http://www.vbdotnetheaven.com/UploadFile/scottlysle/PlaySoundsInASPX09032006083212AM/PlaySoundsInASPX.aspx
Not most appropriate but worth a thought
you can try embedding a silverlight element..
In silverlight you can import the audio file to project
and then can just drag and drop "media element" set source.
drag and drop buttons play and pause..
play : mediasource.play();
pause : mediasource.pause();
voila done.. Its easy to do all this in sileverlight..

Multiple file upload with preview

Is there any good control or plug-in for uploading multiple photos with preview? As far as I understand it is impossible to preview photo on local computer using just JavaScript. So it has to use Flash or Java.
Thanks, also, I use ASP.NET.
Wait, do you mean show it in a browser window before starting the upload? So does the file have a URI? (Hint: file:///c/users/public/somefile.png is a URI) You can always just link it into an image tag on their browser session.
Now, will a browser let you link a file:/// for image? That I've not tried, but you should; at least you'll learn something from it when you do try.
But using this, there's no reason you can't use a lightbox style image viewer with the local URI.
You could also make use of silverlight 4. If you're looking for something already written you might try using the upload control from gallery which much require some hackery or if you have money to burn then telerik have an upload control but I don't believe it supports previews. This http://www.aurigma.com/Products/ImageUploader/ also looks nifty.

Resources