Page 1 of 2

Embedded web cam and DDNS

Posted: Sat 10 Jan 2015 4:04 pm
by andrew_sinclair
Hello,

I have been struggling for a while to display my Foscam web cam embedded into my web page using a no-ip DDNS. No problem at all web I add the actual IP address e.g.

<img src="http://86.135.81.122:2478/CGIProxy.fcgi ... visitor&t=" width="100%" onload='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 1800000)' onerror='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 5000)' alt='cheddarweather web cam' />

Works fine...but

<img src="http://cheddarweatherwebcam.no-ip.org/C ... visitor&t=" width="100%" onload='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 1800000)' onerror='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 5000)' alt='cheddarweather web cam' />

Renders as a broken link.

Although if I type http://cheddarweathercam.no-ip.org/CGIP ... visitor&t= into my browser it works fine.

Advice welcomed.

Regards

Andrew

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 5:13 pm
by vaggos
As i can see you forgot this :2478
It must be:

Code: Select all

<img src="http://cheddarweatherwebcam.no-ip.org:2478/CGIProxy.fcgi?cmd=snapPicture2&usr=visitor&pwd=visitor&t=" width="100%" onload='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 1800000)' onerror='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 5000)' alt='cheddarweather web cam' />
But for better results, look at this: http://foscam.us/forum/showing-secure-m ... t8721.html
I have 5 cams with that simple script.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 8:11 pm
by andrew_sinclair
Hello vaggos,

Thanks for your response. I tried adding :2478 but unfortunately it had the same effect, i.e. renders a broken link. I think I'll try the Foscam US site.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 8:23 pm
by vaggos
Your link http://cheddarweatherwebcam.no-ip.org:2478 its not working as i saw. Did you add cheddarweatherwebcam.no-ip.org to your router to Auto update every time you change IP. You can put it also to your ddns Server on your camera.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 8:54 pm
by andrew_sinclair
Yes, I have added this to my router and also to the widget that no-ip.org provide to do the upload and also to the camera s/w. When I inspect the web par elements it seems that the request is timing out...not sure what this means

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:04 pm
by vaggos
The link http://cheddarweatherwebcam.no-ip.org:2478/ isn't working. Try to manual update it.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:06 pm
by vaggos
And double check if the settings ar correct. User name, password kai your ddns name.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:11 pm
by andrew_sinclair
OK, doubled checked everything and found an error. The no-ip domain was typed incorrectly, it should be

http://cheddarweathercam.no-ip.org

I have checked this and when I type this into the browser bar it works fine. I have changed the code to be

<img src="http://cheddarweathercam.no-ip.org/CGIP ... visitor&t=" width="100%" onload='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 1800000)' onerror='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 5000)' alt='cheddarweather web cam' />

Just checking to see if that works...

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:17 pm
by vaggos
Again the http://cheddarweathercam.no-ip.org:2478/ is not working. You forget the port again in the script.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:18 pm
by vaggos
Check fton no-ip if your ddns name obtain your IP.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:20 pm
by andrew_sinclair
:oops:

Yes, you are correct. The code now reads

<img src="http://cheddarweathercam.no-ip.org:2478 ... visitor&t=" width="100%" onload='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 1800000)' onerror='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 5000)' alt='cheddarweather web cam' /> </p>
<table width="100%" border="0" cellpadding="0" cellspacing="0">

Just uploading the IndexT file now...

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:20 pm
by vaggos
you don't have port 2478. You have the 80. Now its working

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:29 pm
by andrew_sinclair
OK, I think it is working, just checking that it works when embedded in the web page.

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:31 pm
by vaggos
Now you have

Code: Select all

http://cheddarweathercam.no-ip.org:8080/CGIProxy.fcgi?cmd=snapPicture2&usr=visitor&pwd=visitor&t=
Do it

Code: Select all

http://cheddarweathercam.no-ip.org:80/CGIProxy.fcgi?cmd=snapPicture2&usr=visitor&pwd=visitor&t=

Re: Embedded web cam and DDNS

Posted: Mon 12 Jan 2015 9:35 pm
by andrew_sinclair