• November 01, 2024, 03:37:49 AM
  • Welcome, Guest
Please login or register.

Login with username, password and session length
Advanced search  

News:

This Forum Beta is ONLY for registered owners of D-Link products in the USA for which we have created boards at this time.

Pages: [1] 2

Author Topic: Embed Video  (Read 20520 times)

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Embed Video
« on: September 06, 2013, 11:19:03 AM »

Ok... I've seen this topic posted and read all the answers but I just can't get it working the way I want.

I'd like to make a simple web page that allows visitors to view out through my web cam without entering user names and passwords and downloading stuff.  Just can't make it work.

I've got a guest account (non-admin) set up here as guest/guest.  Feel free to take a look if you like.  It's boring.  :)

http://216.xx.xxx.24/eng/liveView.cgi

Problem is it shows all that Dlink stuff around it and it also requires user name and password.  I'm just looking for the video without the dlink stuff and no user name/password.

When I try something like:

http://216.xx.xxx.24/mjpeg.cgi   or anything like that it fails.  I get various plug errors and such-like when I try any of the other existing solutions posted here.  

I've tried every thread on this board that I could find.  Believe me, I've tried them all.  Just need something brain dead simple.  Any ideas?

Many thanks in advance.
« Last Edit: September 10, 2013, 11:20:31 AM by Darkbob »
Logged

RYAT3

  • Level 10 Member
  • *****
  • Posts: 2254
Re: Embed Video
« Reply #1 on: September 06, 2013, 07:33:27 PM »

nothing is working as you say.
 ??? ???
Logged

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Re: Embed Video
« Reply #2 on: September 06, 2013, 08:49:35 PM »

nothing is working as you say.
 ??? ???

Well thanks for trying!  Anybody else with a great idea?  Maybe some setting on my end is wrong?
Logged

RYAT3

  • Level 10 Member
  • *****
  • Posts: 2254
Re: Embed Video
« Reply #3 on: September 07, 2013, 06:34:03 AM »

Well thanks for trying!  Anybody else with a great idea?  Maybe some setting on my end is wrong?

I got in as guest/guest.

it should be something closer to:

http://216.65.178.24/video/mjpg.cgi?profileid=1

http://216.65.178.24/image/jpeg.cgi


Logged

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Re: Embed Video
« Reply #4 on: September 09, 2013, 08:52:56 AM »

Thanks!  I can get in as guest too.  I just want a way to pass the guest info to the camera from a web page to bypass the log-in and make it public.
Logged

Peter von Frosta

  • Level 1 Member
  • *
  • Posts: 7
Re: Embed Video
« Reply #5 on: September 09, 2013, 11:19:49 AM »

just uncheck the "HTTP Authentication"  under "maintenance -> admin"

If you want the livestream in your webpage-design you have to do a browser-Switch.
example in php:
if (strpos(strtolower($_SERVER['HTTP_USER_AGENT']), "msie")) {
<iframe src="http://216.65.178.24/vaview.htm" width="640" height="480" frameborder="0" scrolling="no"></iframe>}
else {
<img src="http://216.65.178.24/video/mjpg.cgi" alt="Livestream" style="width:640px; height:480px;" />
}

I know - an iframe is not really up to date but it works (not for Opera because he canīt handle mjpg)

cheers
« Last Edit: September 09, 2013, 11:31:20 AM by Peter von Frosta »
Logged

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Re: Embed Video
« Reply #6 on: September 10, 2013, 08:53:11 AM »

First, thanks very much for all the help!  Awesome tip on turning off that http authentication.  Is that a security risk by any chance?  They can't get into admin can they?

Anyway I think I have done something wrong but we are getting close.  Can anybody spot my error?

So this is my code:

Code: [Select]
<html>
     <head>
     <title>LiveVideo123x</title>
     <META content="text/html"; charset="UTF-8"; http-equiv=Content-Type>
     <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
     <META HTTP-EQUIV="Expires" CONTENT="-1">
     </head>
     <body>

if (strpos(strtolower($_SERVER['HTTP_USER_AGENT']), "msie")) {
<iframe src="http://216.65.178.24/vaview.htm" width="640" height="480" frameborder="0" scrolling="no"></iframe>}
else {
<img src="http://216.65.178.24/video/mjpg.cgi" alt="Livestream" style="width:640px; height:480px;" />
}

     </body>
     <HEAD>
     <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
     <META HTTP-EQUIV="Expires" CONTENT="-1">
     </HEAD>
</html>

And this is how the screen renders:

Logged

JavaLawyer

  • BETA Tester
  • Level 15 Member
  • *
  • Posts: 12190
  • D-Link Global Forum Moderator
    • FoundFootageCritic
Logged
Find answers here: D-Link ShareCenter FAQ I D-Link Network Camera FAQ
There's no such thing as too many backups FFC

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Re: Embed Video
« Reply #8 on: September 10, 2013, 09:24:37 AM »

Code: [Select]
<html>
     <head>
     <title>LiveVideo123x</title>
     <META content="text/html"; charset="UTF-8"; http-equiv=Content-Type>
     <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
     <META HTTP-EQUIV="Expires" CONTENT="-1">
     </head>
     <body>
     <a href="http://http://216.65.178.24/mjpeg.cgi" rel="self" title="http://216.65.178.24/mjpeg.cgi"> Cam1,
     </a>
     <BR>


     // Note that the video frame size can be arbitrarily configured using the width and
     // height variables located in bold in the HTML code below

     <tr>
        <div class="box">
           <iframe src="http://216.65.178.24/mjpeg.cgi"
           width="460" height="345" class="smart_sizing_iframe noresize"
             frameborder="0" scrolling="no" >
           </iframe>
         </div>
     </tr>

     </body>
     <HEAD>
     <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
     <META HTTP-EQUIV="Expires" CONTENT="-1">
     </HEAD>
     </html>

And here's my screen rendering:

« Last Edit: September 10, 2013, 09:32:48 AM by Darkbob »
Logged

JavaLawyer

  • BETA Tester
  • Level 15 Member
  • *
  • Posts: 12190
  • D-Link Global Forum Moderator
    • FoundFootageCritic
Re: Embed Video
« Reply #9 on: September 10, 2013, 09:26:59 AM »

Thanks for posting another copy of that link.  Seen it a mountain of times.  Messed with it at least 20 times.  Just doesn't even come close to working no matter what I do.  Maybe if I went out and bought two more cameras or something...

Perhaps the contributor for that post (member acellier) will see this thread and help troubleshoot. Alternatively, you can also try sending acellier a PM.
« Last Edit: September 10, 2013, 09:34:21 AM by JavaLawyer »
Logged
Find answers here: D-Link ShareCenter FAQ I D-Link Network Camera FAQ
There's no such thing as too many backups FFC

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Re: Embed Video
« Reply #10 on: September 10, 2013, 09:33:48 AM »

For sure!!  PM him.  I'm dying here.  :)
Logged

JavaLawyer

  • BETA Tester
  • Level 15 Member
  • *
  • Posts: 12190
  • D-Link Global Forum Moderator
    • FoundFootageCritic
Re: Embed Video
« Reply #11 on: September 10, 2013, 09:36:51 AM »

For sure!!  PM him.  I'm dying here.  :)

I just shot him a PM, we'll see what happens!
Logged
Find answers here: D-Link ShareCenter FAQ I D-Link Network Camera FAQ
There's no such thing as too many backups FFC

Peter von Frosta

  • Level 1 Member
  • *
  • Posts: 7
Re: Embed Video
« Reply #12 on: September 10, 2013, 09:52:44 AM »

This example is only working if all of your guests uses Firefox and no IE.
I donīt understand why there are two <head>-declarations in this example. It doesnīt make any sense and is against all rules to build a html-webpage
And the Port addet to the camera-IP is not necessary if you are using only one Camera.
you have two adresses for the Live view.

1. for IE = http://your_camera_ip/vaview.htm
2. for non IE (eg. Firefox) = http://your_camera_ip/video/mjpg.cgi

you have to build a Switch, so the guest with an IE sees "http://your_camera_ip/vaview.htm" and the other guests are seeing "http://your_camera_ip/video/mjpg.cgi".
That coud be easily done with "php" but you have to save your side with the ending *.php and mark your coding as follows:
Code: [Select]
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<?php
if (strpos(strtolower($_SERVER['HTTP_USER_AGENT']), "msie")) { 
echo 
'
<iframe src="http://your_camera_ip/vaview.htm" width="640" height="480" frameborder="0" scrolling="no"></iframe>'
;

else

echo 
'
<img src="http://your_camera_ip/video/mjpg.cgi" alt="Livestream" style="width:640px; height:480px;" />'
;
}
?>

</body>
</html>
« Last Edit: September 10, 2013, 11:20:14 AM by Peter von Frosta »
Logged

Darkbob

  • Level 1 Member
  • *
  • Posts: 18
Re: Embed Video
« Reply #13 on: September 10, 2013, 10:04:02 AM »

Ah!  I think I get it a bit.  I can't just make up an HTML document and save it to my desktop for testing.  I have to make a PHP document and save it to a web server and have the web server run the PHP document or something?

Anyway here's a very simple HTML document that actually does work on all browsers.  It's not exactly live streaming but it reloads every 5 seconds and does more or less what I need with no need to download or install plug-in's or whatever.  Hopefully it will help someone else.

<html>
<head>
<title>CAMERA</title>
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="-1">
<META HTTP-EQUIV="refresh" CONTENT="5">
</head>
<body>
   <img src="http://216.65.178.24/image/jpeg.cgi" alt="Beach Cam">
</body>
</html>

Replace 216.65.178.24 with your own IP address.

Here's the actual web site:

http://mainstayinn.ca

And here's the page (under gallery) with the camera snapshot picture - refresh every 30 sec:

http://mainstayinn.ca/beachcam.html
« Last Edit: September 10, 2013, 10:36:22 AM by Darkbob »
Logged

Peter von Frosta

  • Level 1 Member
  • *
  • Posts: 7
Re: Embed Video
« Reply #14 on: September 10, 2013, 10:21:20 AM »

do you have a static IP? If not, youīll face another Problem...
Logged
Pages: [1] 2