Embed Windows Media Player in PHP - php

Hi how do I go about embeding Windows Media Player in PHP ? what I want is when the user clicks the link a new window pops up to play the video in it's original size & when the user checks the page source he wont find the direct link to the video file, without using activex if possible.

PHP has nothing to do with Windows Media Player. At most it can generate the appropriate HTML to invoke a media player on the client's machine (via <object> and/or <embed> and/or <video>, but there's no guarantee it would be media player. You cannot force a particular player. What if they're on a Mac? Or a Unix machine? No WMP there...
At best you can obscure the address, but when push comes to shove, the address of the media file HAS to be sent to the client so their player can retrieve the data for playing.

Related

Record video on browser and upload to LAMP server

I have tried a lot of things out there: red5, jquery webcam, html5 ... but none of these solution record a video and leave it ready to upload to a server.
Is there anyway (html5, flash, whatever ... the better cross-broswer solution, the best) to upload video (+ audio!) and upload the result to a server (I guess through AJAX) ?
Summarize:
jQueryWebcam (https://github.com/infusion/jQuery-webcam): it has flash video, uploads to a server image, not a video
Eric Bidelman's solution (http://ericbidelman.tumblr.com/post/31486670538/creating-webm-video-from-getusermedia):records video in html5 and allows you to download (so you can upload
to a server), but no audio !
Red5 (http://www.red5-recorder.com/services.php): paid services, not
uploading in free version :(
DMV (https://github.com/rwldrn/dmv): it just captures a photo ... besides not cross-browser
I have developed video recording solutions for the better part of the last 5 years and contributed a lot to fixing video recording bugs in Red5.
There are currently 2 production ready technical solutions for recording audio and video on the web. One for desktop and one for mobile.
On desktop you will need a Flash application that sits embedded in a web page, captures the visitors webcam and mic, encodes the raw video and audio data and streams it as it is recorded (through rtmp) to a media server.
You have at least 3 options for the media server:
Red5 is free and open source (btw. recording works out of the box in Red5)
Wowza ($65/month)
Adobe Media Server Pro ($4500)
The media server receives (again through streaming/rtmp not through http) the data and, depending on the codec used on the client, saves it to mp4, flv or f4v files.
This Flash client + media server recording process - which has worked pretty well since Flash Player 6 in 2002 - will most likely replaced by the HTML5 alternative named MediaStream Recorder (not yet implemented fully by any browser).
On mobile you can use HTML Media Capture (explained here with screenshots) to record video using the device's native video recording app and codecs. HTML Media Capture records locally (on the device) and then you upload (normal HTTP upload process) the file to the web server.
A commercial solution that implements both (Flash client + media server on desktop and HTML Media Capture on mobile) is HDFVR.
You could use something like binary download via javascript.
Here is one example
As you have not much info about video protocols i cant give you better answer
you can try this library, RecordRTC. It generates a blob file to put in video source and you can upload this file later to your server.
RecordRTC Library
This library is a container for other libraries, like Whammy for video, Recorderjs for audio and jsGif for gifs.
You can use Whammy library for record videos too:
Whammy

Prevent Mp3 From Playing In Browser PHP

well currently I have a script which gathers mp3s. All the songs are hosted on external sites.
A user clicking the mp3 link will result in the mp3 playing in the browser in the users default audio player (quicktime etc)
I'm just wondering what code I could use (PHP) to have the mp3 open as a download prompt instead of playing. This would be easy although the catch is that it can't be processed through the server (aka can't use bandwidth)
can it be done?
Thanks
At first glance this appeared to be a duplicate of How to implement Content-Disposition: attachment?.
Then I saw the "3rd party sites" proviso.
There is no way to override the HTTP headers sent by a remote site when sending the client there. What you want is not achievable.

PHP. Requirements. For creating a live video streaming

Our aim is to create a live video streaming site for each individual paid registered user only by php platform.
I need video camera to take videos and i want to know function flow.I dont know where i have to start.
What are all things needed? Especially live video uploading using ordinary video camera. I have found http://www.videowhisper.com/?p=PHP+Live+Streaming This is the site, i exactly needed. Unfortunately but its camera option only includes "webcam only". I would like input video camera instead of webcam.
I need suggestions for requirements to create the site.
I need to stream live video for each paid user. That includes flash player content.
Uploading and video control by admin side. Only live links is shared to customers.
i think it is nothing about PHP, but something about JAVA.
You can use Red5 as media server, and users watch videos via flash player. You also can take videos with flash.
Found an interesting link on it: http://en.wikipedia.org/wiki/Push_technology
And Symfony 2.1 is going to handle streamed responses: http://symfony.com/doc/current/components/http_foundation.html#streaming-a-response, but is not stable yet.

How Facebook image uploading by clicking on "Take a picture" works in mobile?

In my PHP website I want to implement image uploading functionality. So,when I browse or surf Facebook in my mobile browser (iPhone, Android, Symbian OS) I am able to take a picture from my mobile camera and able to upload. I want to use the same functionality in my website but don't know how to do it, or how it works.
For that I searched a lot and found so many results that the idea of "PhoneGap" is useful.
How can I integrate image uploading functionality? When I click on "Take a picture", my mobile's camera should turn on automatically, capture the image and upload it to my website.
Website can't access the image in the image library on iOS. You can;t even upload a file since the file system in accessible.
What tool like phone gap do translate javascript call to native call, but you can only do this in native apps (meaning sending it in the the app store).

Multiple Webcam surveillance within a browser?

I want to create a web application (I am quite good with PHP) that captures webcam shots every 1 minute from different persons that open the application page and sends it via smthng to the web/ftp server.
I mean PC1, PC2 and PC3 opens the web aplication, their webcam it's opened and it captures images every 1 minute so PCSERVER should be able to see the persons behind the webcam "realtime".
I read about Flash Video Server (hope I am quite around the words) but it's purchasable solution and I want to redistribute the application freely.
Any ideas how should I do this?
EDIT:
If I am required to learn another programming language such as ActionScript, I don't mind, but if I am going to learn that, it should resolve my problem.
For video capture and video sharing, you need something like Adobe's Flash Media Server or the open source alternative Red5, that Johni mentions, but since you say you only need "shots every minute", not video, it could also be done without a streaming media server, only the Flash based client and PHP on the server.
What you could do instead of video is capture bitmap images from the web camera, using Flash/ActionScript, encode that bitmap image as JPEG or PNG and upload the image to the server by POSTing it to a PHP page.
It would require more code that fits in a SO Q&A, but you can easily find examples for the different steps of the process - access the web cam - get bitmap image - encode bitmap - POST encoded image top PHP from ActionScript.
The Red5 Media Server is a good open source alternative to the Flash Media Server:
http://red5.org/
It is programmed in Java.

Categories