NEW frontpage.html - request comments

Moderator: leecollings

User avatar
havnegata
Posts: 114
Joined: Wednesday 10 September 2014 11:05
Target OS: Raspberry Pi / ODroid
Domoticz version: V4.10162
Location: Norway
Contact:

Re: NEW frontpage.html - request comments

Post by havnegata »

I've been using G3rard's frontpage for many months now, but suddenly all thats showing is the buienradar and the rest is black. Anyone got an idea of what happened here?
Screen Shot 02-24-17 at 04.05 PM.PNG
Screen Shot 02-24-17 at 04.05 PM.PNG (77.92 KiB) Viewed 8429 times
User avatar
gielie
Posts: 290
Joined: Tuesday 12 January 2016 11:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest β
Location: The Netherlands (Alkmaar)
Contact:

Re: NEW frontpage.html - request comments

Post by gielie »

Ok, i gave this front-page a try and looks very nice, i used G3rard's front-page. But 1 thing i cant figure out.
How and where do setup my camera, i have a foscam within domoticz but i cant figure out how to get this done in the front-page.

can someone point me in the right direction?
- Aeon Labs USB Stick met Z-wave plus
- Aeotec MultiSensor 6
- FIBARO FGS223
- FIBARO FGWPE Wall Plug
- Neo CoolCam Power plug
- Popp Smoke Detector
- Toon
- Kodi Media Server
User avatar
G3rard
Posts: 669
Joined: Wednesday 04 March 2015 22:15
Target OS: -
Domoticz version: No
Location: The Netherlands
Contact:

Re: NEW frontpage.html - request comments

Post by G3rard »

@gielie, you can do the setup of the camera in frontpage.html.

@havnegata, can you check the console (F12 in Chrome) for any messages.
Not using Domoticz anymore
User avatar
havnegata
Posts: 114
Joined: Wednesday 10 September 2014 11:05
Target OS: Raspberry Pi / ODroid
Domoticz version: V4.10162
Location: Norway
Contact:

Re: NEW frontpage.html - request comments

Post by havnegata »

Thanks, will do when I get home
User avatar
havnegata
Posts: 114
Joined: Wednesday 10 September 2014 11:05
Target OS: Raspberry Pi / ODroid
Domoticz version: V4.10162
Location: Norway
Contact:

Re: NEW frontpage.html - request comments

Post by havnegata »

OK, @G3rard, can you point me in the direction as of what to loook for in the console?
User avatar
havnegata
Posts: 114
Joined: Wednesday 10 September 2014 11:05
Target OS: Raspberry Pi / ODroid
Domoticz version: V4.10162
Location: Norway
Contact:

Re: NEW frontpage.html - request comments

Post by havnegata »

I restored a backup and everything is OK now
Ewaldharmsen
Posts: 130
Joined: Tuesday 07 February 2017 15:00
Target OS: Linux
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by Ewaldharmsen »

I want to have push off button to turn off all the light at once.
How do I add that in the frontpage?
jannl
Posts: 639
Joined: Thursday 02 October 2014 6:36
Target OS: Raspberry Pi / ODroid
Domoticz version: 2022.2
Location: Geleen
Contact:

Re: NEW frontpage.html - request comments

Post by jannl »

Just create a virtual button, put that on your frontpage and add some lua to switch of all the lights in a device script.
bsmeding
Posts: 34
Joined: Tuesday 28 October 2014 18:29
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by bsmeding »

Trigun wrote:
albertvandam wrote:Dear all,

With all the examples and code in this forum, I have managed to create a pretty good frontpage which runs on a wall mounted tablet. Thanks to Hansbit, G3rard and all others.
However I can't get to control my Dru Fireplace (Mertik G6R-HT4B) on the frontpage like it should. Directly from Domoticz it works fine.
Does someone have the right json commands to control the Mertik controller?
When I send json commands directly from the Chrome Address Bar, it doesn't work as aspected also.
For example:
http://192.168.4.250:8080/json.htm?type ... itchcmd=up
switches the fire place off!

Thanks in advance for any response.

Image
Hi Albertvandam,

first of all, you did a great job!

is there a chance you can post your frontpage files?
I would love to check it out and see how I can make it fit for my home.

thnx in advance!
Yes I'm also interested in a extra column. Will be very happy if you can share your settings :D
User avatar
gielie
Posts: 290
Joined: Tuesday 12 January 2016 11:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest β
Location: The Netherlands (Alkmaar)
Contact:

Re: NEW frontpage.html - request comments

Post by gielie »

@G3rard Yes, thanks for the help, it works now.

There is only one thing about the camera, i have a foscam R2 and within frontpage i only get an fixed image and no streaming video, is this possible? What should i change? Within Domticz streaming works fine and i use the same url as in my Domoticz camera settings (Ip-adres:port/cgi-bin/CGIProxy.fcgi?cmd=snapPicture2&usr=user&pwd=password&)
- Aeon Labs USB Stick met Z-wave plus
- Aeotec MultiSensor 6
- FIBARO FGS223
- FIBARO FGWPE Wall Plug
- Neo CoolCam Power plug
- Popp Smoke Detector
- Toon
- Kodi Media Server
Ewaldharmsen
Posts: 130
Joined: Tuesday 07 February 2017 15:00
Target OS: Linux
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by Ewaldharmsen »

@Jannl, thanks.

I found my answer on line 159 of frontpage.js
But if I change it like this:

Code: Select all

	if (item.SwitchType == 'Push Off Button') {
		vdata = '<img src=icons/off_button.png>'
	}
It is non-clickable.

So I still have the quesition: how can I change the look of one particular button?
Last edited by Ewaldharmsen on Tuesday 28 February 2017 21:21, edited 1 time in total.
Ewaldharmsen
Posts: 130
Joined: Tuesday 07 February 2017 15:00
Target OS: Linux
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by Ewaldharmsen »

When I click on cell26 it tries to open up 192.168.1.1, which cannot be found.

I cannot find where that is defined.
Can someone guide me?
It is not in frontpage.html, frontpage.js nor frontpage_settings.js..
User avatar
G3rard
Posts: 669
Joined: Wednesday 04 March 2015 22:15
Target OS: -
Domoticz version: No
Location: The Netherlands
Contact:

Re: NEW frontpage.html - request comments

Post by G3rard »

@gielie,

I use this code to show a picture from the camera using Domoticz, where 5 is the idx of the camera in Domoticz.

Code: Select all

<img src="http://192.168.1.157:8084/camsnapshot.jpg?idx=5&t="  onClick="lightbox_open('camera1', 92400);" width="200px" class='camera' />
And when I click on the picture the video is shown (which is actually pictures being reloaded very quickly) using the following code.

Code: Select all

<div id="popup_camera1"><img src="http://192.168.1.157:8084/camsnapshot.jpg?idx=5&t=" onClick="lightbox_close('camera1');" width="640" height="480" onload='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 100)' onerror='setTimeout(function() {src = src.substring(0, (src.lastIndexOf("t=")+2))+(new Date()).getTime()}, 1000)' class='bigcamera' /></div>
This code is somewhere on the bottom of frontpage.html.

This way the video is only shown when you click on the picture, this saves some network traffic.

Domoticz is using the same trick by reloading the pictures very quickly so it looks like a streaming video.
But as you can see in the url of your camera, it is actually showing you a picture.

Other option is that you google the streaming video url for your camera and use that in the frontpage.
Not using Domoticz anymore
Ierlandfan
Posts: 89
Joined: Friday 09 October 2015 17:40
Target OS: Linux
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by Ierlandfan »

Does anyone how to create this? I think I need to change frontpage.html and mess with css?
Attachments
frontpage (Small).png
frontpage (Small).png (347.14 KiB) Viewed 8092 times
User avatar
gielie
Posts: 290
Joined: Tuesday 12 January 2016 11:40
Target OS: Raspberry Pi / ODroid
Domoticz version: latest β
Location: The Netherlands (Alkmaar)
Contact:

Re: NEW frontpage.html - request comments

Post by gielie »

Ok i figured out why i can't get a stream but only a steady picture.
My camera doesn't support mjpeg, it only supports H.264 and it needs a different url like this, rtsp://username:pwd@IP:port/videoMain burt i can't get this to work, does the script support rasp? Within VLC i can check if the url works and it does, anybody an idea?
- Aeon Labs USB Stick met Z-wave plus
- Aeotec MultiSensor 6
- FIBARO FGS223
- FIBARO FGWPE Wall Plug
- Neo CoolCam Power plug
- Popp Smoke Detector
- Toon
- Kodi Media Server
leffert
Posts: 2
Joined: Friday 17 March 2017 15:46
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by leffert »

Can the frontpage.html dashboard be password protected?
Can it be run, or does it lose any functionallity if it is run from a webhotel outside of home (protected by htaccess or login system)?

How do you solve this?
jannl
Posts: 639
Joined: Thursday 02 October 2014 6:36
Target OS: Raspberry Pi / ODroid
Domoticz version: 2022.2
Location: Geleen
Contact:

Re: RE: Re: NEW frontpage.html - request comments

Post by jannl »

leffert wrote:Can the frontpage.html dashboard be password protected?
Can it be run, or does it lose any functionallity if it is run from a webhotel outside of home (protected by htaccess or login system)?

How do you solve this?
I solve this by using a vpn
Ewaldharmsen
Posts: 130
Joined: Tuesday 07 February 2017 15:00
Target OS: Linux
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by Ewaldharmsen »

Got an excellent frontpage, thank you all!

I change it a bit:
* Made it responsive
* I am using a uservariable instead of a virtual switch
* In phone mode I put the switches on the top of the page:
TabletLandscapeMode.jpeg
TabletLandscapeMode.jpeg (141.75 KiB) Viewed 7712 times
Phone.jpg
Phone.jpg (36.9 KiB) Viewed 7712 times
Laptop.jpg
Laptop.jpg (374.01 KiB) Viewed 7712 times
Ewaldharmsen
Posts: 130
Joined: Tuesday 07 February 2017 15:00
Target OS: Linux
Domoticz version:
Contact:

Re: NEW frontpage.html - request comments

Post by Ewaldharmsen »

TabletPortraitMode.jpeg
TabletPortraitMode.jpeg (73 KiB) Viewed 8054 times
Last edited by Ewaldharmsen on Monday 20 March 2017 18:45, edited 1 time in total.
Trigun
Posts: 390
Joined: Wednesday 30 November 2016 11:58
Target OS: Raspberry Pi / ODroid
Domoticz version: 4.10717
Contact:

Re: NEW frontpage.html - request comments

Post by Trigun »

Hi Ewald, it looks amazing! Especially the responsive part! Is there a chance you can share your config? Cheers!!


Sent from my iPhone using Tapatalk
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests