NEW frontpage.html - request comments
Moderator: leecollings
- mvveelen
- Posts: 678
- Joined: Friday 31 October 2014 10:22
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Hoorn, The Netherlands
- Contact:
Re: NEW frontpage.html - request comments
@ FutureCow : how did you get the Skycons (?) in there? If they are Skycons ?
Can you share your code? Maybe others like to use (some of) it.
Can you share your code? Maybe others like to use (some of) it.
RPi3b+/RFXCOM rfxtrx433E/Shelly/Xiaomi Gateway/Philips HUE Lights/Atag Zone One/2 SunnyBoy inverters/AirconWithMe/P1 smartmeter/Domoticz latest Beta
-
- Posts: 8
- Joined: Monday 30 December 2013 9:00
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: NEW frontpage.html - request comments
After more than one hour of trying, i gave up...mvveelen wrote:@ FutureCow : how did you get the Skycons (?) in there? Can you share your code?
I've made a gif for every icon, took me only 10 minutes for all the icons... I can share the gifs, but with the background!(i can create white with black background if people are interested)
- mvveelen
- Posts: 678
- Joined: Friday 31 October 2014 10:22
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Hoorn, The Netherlands
- Contact:
Re: NEW frontpage.html - request comments
If you can make both? Or, can't you make them with a transparent background?
I don't understand why it isn't possible to add the Skycons..... jan_nl ? bbqkees ?
I don't understand why it isn't possible to add the Skycons..... jan_nl ? bbqkees ?
RPi3b+/RFXCOM rfxtrx433E/Shelly/Xiaomi Gateway/Philips HUE Lights/Atag Zone One/2 SunnyBoy inverters/AirconWithMe/P1 smartmeter/Domoticz latest Beta
-
- Posts: 75
- Joined: Sunday 30 November 2014 8:41
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Hoorn, Netherlands
- Contact:
Re: NEW frontpage.html - request comments
I guess it's possible to save them as *.png file, which supports transparent as far as I know.
Jan_nl, about the icons directory and his files! where do I get them? In what version of front page.html or whatever where they in?
Jan_nl, about the icons directory and his files! where do I get them? In what version of front page.html or whatever where they in?
-
- Posts: 278
- Joined: Sunday 14 December 2014 12:28
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.11375
- Contact:
Re: NEW frontpage.html - request comments
How do i get the the sunrise and sunset in a cell?
- mvveelen
- Posts: 678
- Joined: Friday 31 October 2014 10:22
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Hoorn, The Netherlands
- Contact:
Re: NEW frontpage.html - request comments
Would it be possible to post the pieces of code, stating where you have to put them, and in which file? That way people can use the pieces they want.jan_nl wrote:Added some sort of traffic info, max 4 traffic-jams, the text is clickable and brings you to http://www.anwb.nl/verkeer (which is not configurable (not yet anyway)).
Changes in frontpage.css (cell2_3), frontpages_settings.js and frontpage.js
I also added a script (wget_verkeer.sh) to get an rss feed from verkeerplaza, so this propably only works in the Netherlands. This scripts must run via crontab (changes about every minute)
This method is used by bulletin boards, when they make 'mods' (modifications). I think this will make it a lot easier for everybody to help improve the frontpage.
Sure, this will take a some more energy and time, but what about he users who have other ideas from which everyone can profit?
Example (it shows which file to edit and where to add or replace a piece of code -> see how important the comments are ?) :
Code: Select all
<edit file>
Themes/default/Display.template.php
</edit file>
<search>
// Show the anchor for the top and for the first message. If the first message is new, say so.
</search>
<replace>
global $bar_exps, $bar_posts;
// Show the anchor for the top and for the first message. If the first message is new, say so.
</replace>
RPi3b+/RFXCOM rfxtrx433E/Shelly/Xiaomi Gateway/Philips HUE Lights/Atag Zone One/2 SunnyBoy inverters/AirconWithMe/P1 smartmeter/Domoticz latest Beta
-
- Posts: 113
- Joined: Thursday 20 November 2014 22:11
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Norway
- Contact:
Re: NEW frontpage.html - request comments
Great work with the sunrise/sunset option jan_nl!jan_nl wrote:And yet another update.
Changes are the possibility to add sunrise/sunset to a cell.
Changes are in frontpage_settings.js (enabling option and 3 new var's) and frontpage.js bottom and top of main refresh function
If you use the included css, remember it is made smaller to fit my 7" tablet.
I noticed the weather icons were somewhat dragged in the latest release. I changed the width to the same value as the height to get the right dimentions. Worked for the current weatherstatye here, haven't controlled the others yet.
Anyway, here's the code-part form frontpage.js:
Code: Select all
// replace forecast (text) with an image
if (vdata == 'Sunny' ) {
vdata=new String(vdata).replace( "Sunny","<img src=icons/day_sun.png width=155 height=155>");
}
if (vdata == 'Partly Cloudy' ) {
vdata=new String(vdata).replace( "Partly Cloudy","<img src=icons/day-partlycloudy.png width=155 height=155>");
}
if (vdata == 'Cloudy' ) {
vdata=new String(vdata).replace( "Cloudy","<img src=icons/day-cloudy.png width=155 height=155>");
}
if (vdata == 'Clear' ) {
vdata=new String(vdata).replace( "Clear","<img src=icons/day_sun.png width=155 height=155>");
}
if (vdata == 'Rain' ) {
vdata=new String(vdata).replace( "Rain","<img src=icons/day-rain.png width=155 height=155>");
}
if (vdata == 'Snow' ) {
vdata=new String(vdata).replace( "Snow","<img src=icons/day-snow.png width=155 height=155>");
}
if (vdata == 'Fog' ) {
vdata=new String(vdata).replace( "Fog","<img src=icons/day-fog.png width=155 height=155>");
}
if (vdata == 'Hail' ) {
vdata=new String(vdata).replace( "Hail","<img src=icons/day-hail.png width=155 height=155>");
}
if (vdata == 'Thunderstom' ) {
vdata=new String(vdata).replace( "Thunderstorm","<img src=icons/day-thunder.png width=155 height=155>");
}
if (vdata == 'Sleet' ) {
vdata=new String(vdata).replace( "Sleet","<img src=icons/day-sleet.png width=155 height=155>");
}
Last edited by thorbj on Tuesday 03 February 2015 11:15, edited 1 time in total.
2xRaspberry Pi Model 2 w/RaZberry z-wave chip (master/slave)|Fibaro Wall Plug|Fibaro Universal Dimmer 500W|Aeon Labs Multisensor|RFXtrx433E|Nexa WMR-1000|Nexa Pe-3|Nexa Remote|Nexa LGDR3500|Lightify Gateway|Lightify RGBW bulb
-
- Posts: 113
- Joined: Thursday 20 November 2014 22:11
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Norway
- Contact:
Re: NEW frontpage.html - request comments
I took the liberty to rewrite the time/date function in frontpage.js so it would display the date in the following format: 3. feb 2015 hh:mm
If someone wants it to display "the american way" like Month Day. Year, you can switch the second-last string with:
Code: Select all
//Return current time: dd. month yyyy hh:mm
function currentTime() {
var today=new Date();
var h=today.getHours().toString();
h = h.trim();
if (h.length == 1) {
h = '0'+ h;
}
var m=today.getMinutes().toString();
m = m.trim();
if (m.length == 1) {
m = '0'+ m;
}
var day=today.getDate().toString();
day = day.trim();
//Change the months to reflect your preferred translation
var month = new Array();
month[0] = "jan.";
month[1] = "feb.";
month[2] = "mar.";
month[3] = "apr.";
month[4] = "may";
month[5] = "jun.";
month[6] = "jul.";
month[7] = "aug.";
month[8] = "sept.";
month[9] = "oct.";
month[10] = "nov.";
month[11] = "dec.";
var month = month[today.getMonth()];
var year=today.getFullYear();
//To display month first, change the following string to
//var ret_str=month+" "+day+". "+year+" "+h+":"+m;
var ret_str=day+". "+month+" "+year+" "+h+":"+m;
return ret_str;
}
Code: Select all
var ret_str=month+" "+day+". "+year+" "+h+":"+m;
2xRaspberry Pi Model 2 w/RaZberry z-wave chip (master/slave)|Fibaro Wall Plug|Fibaro Universal Dimmer 500W|Aeon Labs Multisensor|RFXtrx433E|Nexa WMR-1000|Nexa Pe-3|Nexa Remote|Nexa LGDR3500|Lightify Gateway|Lightify RGBW bulb
-
- Posts: 113
- Joined: Thursday 20 November 2014 22:11
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Norway
- Contact:
Re: NEW frontpage.html - request comments
Is it possible to add °C after the value in temp cells?
2xRaspberry Pi Model 2 w/RaZberry z-wave chip (master/slave)|Fibaro Wall Plug|Fibaro Universal Dimmer 500W|Aeon Labs Multisensor|RFXtrx433E|Nexa WMR-1000|Nexa Pe-3|Nexa Remote|Nexa LGDR3500|Lightify Gateway|Lightify RGBW bulb
-
- Posts: 278
- Joined: Sunday 14 December 2014 12:28
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.11375
- Contact:
Re: NEW frontpage.html - request comments
Can someone please tell me howto use the sunrise/sunset option
-
- Posts: 113
- Joined: Thursday 20 November 2014 22:11
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Location: Norway
- Contact:
Re: NEW frontpage.html - request comments
SwordFish wrote:Can someone please tell me howto use the sunrise/sunset option
Code: Select all
['29','Sun', 'cell21', '','0','0','color:#17E213;font-size:50$'],
2xRaspberry Pi Model 2 w/RaZberry z-wave chip (master/slave)|Fibaro Wall Plug|Fibaro Universal Dimmer 500W|Aeon Labs Multisensor|RFXtrx433E|Nexa WMR-1000|Nexa Pe-3|Nexa Remote|Nexa LGDR3500|Lightify Gateway|Lightify RGBW bulb
-
- Posts: 278
- Joined: Sunday 14 December 2014 12:28
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.11375
- Contact:
Re: NEW frontpage.html - request comments
Thanks, but do i have to make a dummy switch for the sunrise and sunset?thorbj wrote:SwordFish wrote:Can someone please tell me howto use the sunrise/sunset optionin frontpage_settings.js worked for me.Code: Select all
['29','Sun', 'cell21', '','0','0','color:#17E213;font-size:50$'],
-
- Posts: 625
- 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
No you don't. Take care, better use 0 instead of 29. And you now can use SunBoth, SunRise and SunSet as well.I had some stand issues when using an existing idx by accident.
I downloaded the icons from a link on this forum. I will post them here in several files today of tomorrow
@mvveelen: I understand the need for mods, however I don't really understand how. Comments in the code are present, more or less. But I will make it more clear with future changes
I downloaded the icons from a link on this forum. I will post them here in several files today of tomorrow
@mvveelen: I understand the need for mods, however I don't really understand how. Comments in the code are present, more or less. But I will make it more clear with future changes
-
- Posts: 11
- Joined: Sunday 04 January 2015 16:04
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: NEW frontpage.html - request comments
Is it possible to add NS train information?
And can I make the second page as start page?
And can I make the second page as start page?
-
- Posts: 278
- Joined: Sunday 14 December 2014 12:28
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.11375
- Contact:
Re: NEW frontpage.html - request comments
Thanks that works. But now i want to get sunsrise in one cell en sunset in another cell. I have now set idx '0' and value 'Sun'. when i put 'SunRise' in the value i get nothing? Is there something i have to change?jan_nl wrote:No you don't. Take care, better use 0 instead of 29. And you now can use SunBoth, SunRise and SunSet as well.I had some stand issues when using an existing idx by accident.
I downloaded the icons from a link on this forum. I will post them here in several files today of tomorrow
@mvveelen: I understand the need for mods, however I don't really understand how. Comments in the code are present, more or less. But I will make it more clear with future changes
- bbqkees
- Posts: 407
- Joined: Sunday 17 August 2014 21:01
- Target OS: Linux
- Domoticz version: 4.1x
- Location: The Netherlands
- Contact:
Re: NEW frontpage.html - request comments
I missed a few days over here and in the mean time this topic kind of exploded.
Is everything working right now in respect to dimming, thermostat and the correct amount of swipe-able pages?
Seems so.
I looked into the skycons issue, but I have not resolved that yet. The alternative solution with the GIF files could be an easy sidestep of the problem.
Is everything working right now in respect to dimming, thermostat and the correct amount of swipe-able pages?
Seems so.
I looked into the skycons issue, but I have not resolved that yet. The alternative solution with the GIF files could be an easy sidestep of the problem.
Bosch / Nefit / Buderus / Junkers / Worcester / Sieger EMS bus Wi-Fi MQTT Gateway and interface boards: https://bbqkees-electronics.nl/
-
- Posts: 129
- Joined: Monday 25 November 2013 17:51
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2021.1
- Location: Mallorca
- Contact:
Re: NEW frontpage.html - request comments
@bbqkees
Is this fixed already?
I created a virtual setpoint device, I now see I need to send another command for those devices.
/json.htm?type=command¶m=udevice&idx=93&nvalue=0&svalue=21.5
But I can fix that this weekend.
Is this fixed already?
Rfxcom
Raspi 4
Raspi 4
-
- Posts: 75
- Joined: Sunday 30 November 2014 8:41
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Hoorn, Netherlands
- Contact:
Re: NEW frontpage.html - request comments
For now i created 2 virtual push buttons;
on, with 'aan actie' and 'uit actie'
http://192.168.1.56:1720/json.htm?type= ... value=17.5
off, with 'aan actie' and ´uit actie'
http://192.168.1.56:1720/json.htm?type= ... value=15.5
I haven't tried it since your last update with the thermostat, which didnt work.
bbqkees, did it all worked wel with building the house?
Floris
on, with 'aan actie' and 'uit actie'
http://192.168.1.56:1720/json.htm?type= ... value=17.5
off, with 'aan actie' and ´uit actie'
http://192.168.1.56:1720/json.htm?type= ... value=15.5
I haven't tried it since your last update with the thermostat, which didnt work.
bbqkees, did it all worked wel with building the house?
Floris
Re: NEW frontpage.html - request comments
Hi
Is it possible to get battery level and if the device is online/offline?
Is it possible to get battery level and if the device is online/offline?
-
- Posts: 12
- Joined: Monday 02 February 2015 16:15
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: NEW frontpage.html - request comments
I have entered my IDX doorbell and my frontdoorcamera is working in frontpage. But when I press the doorbell there will be no popup. How can I make it work .
I tried Chime, On and Group On but no luck.
I tried Chime, On and Group On but no luck.
Rpi-Domoticz +RFXtrx433E | Rpi-Openelec | Rpi-Runeaudio | unRaid 6 server | Intel NUC-Linux Tvheadend + Oscam
Who is online
Users browsing this forum: No registered users and 1 guest