Answer the question
In order to leave comments, you need to log in
How to get an image from a live camera in php or js?
Guys, hello everyone.
A question. There is a site that shows online cameras of the city.
I need to get an image, how can this be done. When I take a screenshot of the page with this video, it does not display anything.
Is it possible to do this at all and how?
Answer the question
In order to leave comments, you need to log in
Kirill Gorelov regularly pick up the jepag what's going on therephoto
$link="http://rtsp.me/ff.php?camId=j60tUEa7";
$ch = curl_init();
curl_setopt($ch, CURLOPT_POST, 0);
curl_setopt($ch,CURLOPT_URL,$link);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$cu_result=curl_exec($ch);
curl_close($ch);
$savefile = fopen('/home/user/image.jpg', 'w');
fwrite($savefile, $cu_result);
fclose($savefile);
you must first fully load the page and then take a screenshot, because the player loads for half a second
Is there a video stream or consecutive photos (from the phone, I can’t look)? If the photos - you can get a link, and download a crown once a minute.
There was a similar case with webcams from the NASA hangar, there were cameras that updated the image every minute. Personally, I came up with this option
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question