Page 39 of 66

Re: NEW frontpage.html - request comments

Posted: Monday 09 November 2015 22:37
by G3rard
There is no other documentation, but let my try to help you.

You have to use the IP of your Sonos in the config.php, not the IP of the Pi.
Part of the config.php where 115 is the IDX in Domoticz.

Code: Select all

'zones' => array(
      '115'   => '192.168.1.161', /* kitchen*/
	),
The url you have to use in this example is:

Code: Select all

http://yourserver/tablet/sonos/index.php?zone=115&action=Play
And you have to run the PHP on a PHP enabled web server. So if that's not installed on your Pi, you have to install PHP on it.

Re: NEW frontpage.html - request comments

Posted: Tuesday 10 November 2015 10:54
by grelle
Thankyou for your reply! My guess is that PHP is not working but this makes me wonder...

How does Domoticz work with webserver, Is not Domoticz using PHP too ? I can find scripts in Domoticz wiki about PHP, will look into this further today. Maybe the problem is my subfolder "tablet".

Re: NEW frontpage.html - request comments

Posted: Tuesday 10 November 2015 17:26
by grelle
Indeed, installed php5 and apache2 and moved sonos folder to /var/www/ which is the root of apache webdocs. Edited the "on" and "off" links in my Domoticz dummy switch and voila!

Wonderful. Thank you for sharing this piece of code!

Re: NEW frontpage.html - request comments

Posted: Thursday 12 November 2015 13:53
by woods
Stupid question, please don't laugh!

How do I find the 'www' folder on my Raspberry Pi 2? I'm trying to follow some guides, but I can't figure out how to start. I've tried to use 'putty' and can't find any directory called 'www', if I try to 'sudo www'.

Thanks for the help!

Ps. Is there any ELI5 guides on this?

Re: NEW frontpage.html - request comments

Posted: Thursday 12 November 2015 14:24
by pj-r
woods wrote:How do I find the 'www' folder on my Raspberry Pi 2? I'm trying to follow some guides, but I can't figure out how to start. I've tried to use 'putty' and can't find any directory called 'www', if I try to 'sudo www'.
This quide might help a little. And then its about are you looking for www folder of apache or domoticz. Look for /var/www and /home/pi/domoticz/www.

Re: NEW frontpage.html - request comments

Posted: Wednesday 18 November 2015 0:41
by Minimac
Hello..

I Have the same question about the www folder on a Raspberry PI.
I have my domoticz system working om a windows machine and now i want to switch to the Raspberry.

could someone tell me how to put the Frontpage fils into the www folder on a Raspberry PI

Thanx..

Re: NEW frontpage.html - request comments

Posted: Thursday 19 November 2015 15:35
by Kohen
First of all, looking great!
Second , I've been reading the whole topic but now I'm wondering, what's the latest version? :)

Re: NEW frontpage.html - request comments

Posted: Tuesday 24 November 2015 13:17
by 1bigwink
This is a great feature for Domoticz - thanks for sharing it. As a newbie though I am struggling to create my own frontpage, even after reading through the whole thread... I'm having problems getting my IP Cam working and the popup to work with the doorbell, as well as 'on click' functions (e.g. show the thermostat up/down buttons when the temp value is clicked) is there a set of instructions anywhere? If there isn't could we get this added to the Domoticz wiki? I'd be happy to contribute myself as I learn (might need some pointers along the way though).
Thanks again!

Re: NEW frontpage.html - request comments

Posted: Tuesday 24 November 2015 13:20
by 1bigwink
Minimac wrote:Hello..
could someone tell me how to put the Frontpage fils into the www folder on a Raspberry PI
Thanx..
I connected via SFTP using an FTP client and default pi crednetials - then copied all the frontpage files into /home/pi/domoticz/www/
Kohen wrote:First of all, looking great!
Second , I've been reading the whole topic but now I'm wondering, what's the latest version? :)
From what I can see the latest version is https://github.com/gerard33/frontpage, not sure if this is the original authors but works for me.

Re: NEW frontpage.html - request comments

Posted: Wednesday 25 November 2015 23:32
by G3rard
1bigwink wrote:This is a great feature for Domoticz - thanks for sharing it. As a newbie though I am struggling to create my own frontpage, even after reading through the whole thread... I'm having problems getting my IP Cam working and the popup to work with the doorbell, as well as 'on click' functions (e.g. show the thermostat up/down buttons when the temp value is clicked) is there a set of instructions anywhere? If there isn't could we get this added to the Domoticz wiki? I'd be happy to contribute myself as I learn (might need some pointers along the way though).
Thanks again!
What is the problem with the IP cam? Is it working in Domoticz? In that case you can also use the following in the frontpage.html (cell 25 is just an example).

Code: Select all

<div id="frame">
	<div id="ls_cell25"></div><div id="cell25">
	<img src="http://<domoticzip:port>/camsnapshot.jpg?idx=3&t=" onClick="lightbox_open('camera1', 92400);" width="200px" class='camera' /></div>
	<div id="bcell25"></div>
	<div id="desc_cell25">Buiten</div>
</div>
Replace the 3 after idx with the corresponding idx of the camera.

For the popup in the doorbell I use the following code in frontpage.js.

Code: Select all

//doorbell
	if (item.idx == idx_doorbell && vdata == doorbell_status) {
		lightbox_open('camera1', 15400);
		vdata=new String(vdata).replace( "On", "Tringgg");
	}
And in frontpage_settings.js.

Code: Select all

<!-- This triggers the camera PopUp when the doorbell is pressed -->
<!-- Text could be 'On', 'Group On' or 'Chime' -->
var doorbell_status = 'On';
var idx_doorbell = '200'; //dummy switch which goes on when doorbell rings, goes off after 10 seconds
var doorbell_cmd = "lightbox_open('camera1', 15400);"
I have made a dummy switch (idx 200) in Domoticz which goes on when the doorbell rings and goes off after 10 seconds.

How does you Thermostat line look like? Is the last value before the ] a 1? Then it should show the plus and min buttons.

Re: NEW frontpage.html - request comments

Posted: Thursday 26 November 2015 13:46
by havnegata
Help me understand.

My goal is to start all over with clean sheets regarding the frontpage from G3rard. Recently I've experimenting with lots of different versions of frontpages, but now I wanted to start all over, so I deleted everything regarding frontpagefolders and downloaded the last version from G3rard. Still, trying to open the new frontpage.html (192.168.1.160:7050/frontpage.html) without editing any idx, I get my old frontpage with edited idx. Any advice is much appreciated

Edit: If I move frontpage.html from "c:\domoticz\www\" to "c:\domoticz\www\frontpage\" and then open it it's clean, but then it's not rechable from 192.168.1.160:7050/frontpage.html

Re: NEW frontpage.html - request comments

Posted: Thursday 26 November 2015 15:35
by jannl
Did you also replace the frontpage.html?

Re: NEW frontpage.html - request comments

Posted: Thursday 26 November 2015 16:13
by havnegata
Yes, it's the same file, but appears differently in different locations

Sent from my LG-D855 using Tapatalk

Re: NEW frontpage.html - request comments

Posted: Thursday 26 November 2015 16:28
by jannl
You better search your system for duplicate versions of those files/directorys

Re: NEW frontpage.html - request comments

Posted: Thursday 26 November 2015 16:34
by G3rard
havnegata wrote:Help me understand.

My goal is to start all over with clean sheets regarding the frontpage from G3rard. Recently I've experimenting with lots of different versions of frontpages, but now I wanted to start all over, so I deleted everything regarding frontpagefolders and downloaded the last version from G3rard. Still, trying to open the new frontpage.html (192.168.1.160:7050/frontpage.html) without editing any idx, I get my old frontpage with edited idx. Any advice is much appreciated

Edit: If I move frontpage.html from "c:\domoticz\www\" to "c:\domoticz\www\frontpage\" and then open it it's clean, but then it's not rechable from 192.168.1.160:7050/frontpage.html
Try to install it in c:\domoticz\www\frontpage\ and use 192.168.1.160:7050/frontpage/frontpage.html to open the frontpage.

Re: NEW frontpage.html - request comments

Posted: Thursday 26 November 2015 16:43
by havnegata
Thanks!! That did the trick, but do you have any idea how this happened? Some sort of cache or what?

Sent from my LG-D855 using Tapatalk

Re: NEW frontpage.html - request comments

Posted: Saturday 28 November 2015 23:40
by havnegata
So far so good! I'm reading G3rard's post on how to get the alarm working: http://www.domoticz.com/forum/viewtopic ... nel#p38181
I have the icon correct and the security panel pops up, but when I try to push the numbers for my code nothing happens, only sound. Any ideas?

Re: NEW frontpage.html - request comments

Posted: Sunday 29 November 2015 13:16
by SwordFish
G3rard, how do I get the 33dimmer.png enz to work?
Nice frontpage.

Re: NEW frontpage.html - request comments

Posted: Sunday 29 November 2015 14:57
by G3rard
havnegata wrote:So far so good! I'm reading G3rard's post on how to get the alarm working: http://www.domoticz.com/forum/viewtopic ... nel#p38181
I have the icon correct and the security panel pops up, but when I try to push the numbers for my code nothing happens, only sound. Any ideas?
Which browser are you using? I use Chrome and it works over here.

Re: NEW frontpage.html - request comments

Posted: Sunday 29 November 2015 15:09
by G3rard
SwordFish wrote:G3rard, how do I get the 33dimmer.png enz to work?
Nice frontpage.
Thanks.

Did you already check this post?
http://www.domoticz.com/forum/viewtopic ... mer#p37199
I am not using that function so let me know if this doesn't work then I will have another look at it.