Welcome to the Cumulus Support forum.

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Cumulus MX V4 beta test release 4.0.0 (build 4018) - 28 March 2024

Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

Sparklines

Other discussion about creating web sites for Cumulus that doesn't have a specific subforum

Moderator: daj

User avatar
jdc
Posts: 142
Joined: Tue 19 Jun 2012 8:51 pm
Weather Station: Davis VP2 : Instromet
Operating System: Win 10
Location: Portsoy,.
Contact:

Sparklines

Post by jdc »

I know this has been done before but.....
I have been in conversation with several people regarding 'Sparklines' recently. I have been using them for quite a few years with phpwebtags and decided to simplify my scripts and make them available.
The main proviso is I am not a skilled scripter and I'm sure there are better/more efficient ways to produce the same end result.
I do not know if commas as decimal marks will work.
This method uses php webtags - a basic set supplied.
Limited customisation - colour, size, parameters.
I have tried to 'keep it simple' so it should be straightforward to get sparklines up and running on your site.
Just read the README first!
You do not have the required permissions to view the files attached to this post.
Last edited by jdc on Sun 24 Jun 2018 10:07 am, edited 1 time in total.
User avatar
beteljuice
Posts: 3292
Joined: Tue 09 Dec 2008 1:37 pm
Weather Station: None !
Operating System: W10 - Threadripper 16core, etc
Location: Dudley, West Midlands, UK

Re: Sparklines

Post by beteljuice »

Welcome to the dark side John :lol:
Image
......................Imagine, what you will KNOW tomorrow !
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

yep john got them all working on my test page

http://www.davisworthing.co.uk/new/one.php
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
User avatar
jdc
Posts: 142
Joined: Tue 19 Jun 2012 8:51 pm
Weather Station: Davis VP2 : Instromet
Operating System: Win 10
Location: Portsoy,.
Contact:

Re: Sparklines

Post by jdc »

Welcome to the dark side John :lol:
Thank you, Emperor.
yep john got them all working on my test page
Great! I see you've added more parameters too.
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

yh i done all off them mate do u want me to zip it back up and send it to u as it took a long time to add all of them ?
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
User avatar
jdc
Posts: 142
Joined: Tue 19 Jun 2012 8:51 pm
Weather Station: Davis VP2 : Instromet
Operating System: Win 10
Location: Portsoy,.
Contact:

Re: Sparklines

Post by jdc »

That would be good - thanks.
I will leave the 'basic' settings and have your extras as an add-on.
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

here you go jdc
You do not have the required permissions to view the files attached to this post.
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
mitmania
Posts: 37
Joined: Tue 07 Feb 2012 11:51 am
Weather Station: WS2350 & Davis VP2
Operating System: Win 7
Location: Italy
Contact:

Re: Sparklines

Post by mitmania »

Hello everyone, I use Cumulus 1.9 and I would like to integrate these fantastic graphics on my home page. I can not find the file cuumuluswebtags.txt .... where am I wrong?

Thank you!
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

sorry mate it there but in php formate but here is the txt file aswell
You do not have the required permissions to view the files attached to this post.
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
User avatar
jdc
Posts: 142
Joined: Tue 19 Jun 2012 8:51 pm
Weather Station: Davis VP2 : Instromet
Operating System: Win 10
Location: Portsoy,.
Contact:

Re: Sparklines

Post by jdc »

You don't need a full cumuluswebtags.txt there is sparklines_tags.txt in the zipped file purely for Sparklines.
The Readme explains how to use it with Cumulus.
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

yh John i think he downloaded my zip up one and my one was cuumuluswebtags.php not

cuumuluswebtags.txt
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
mitmania
Posts: 37
Joined: Tue 07 Feb 2012 11:51 am
Weather Station: WS2350 & Davis VP2
Operating System: Win 7
Location: Italy
Contact:

Re: Sparklines

Post by mitmania »

Hi, unfortunately I can not configure this script .... are not clear the steps below taken from the file readme.txt, especially the second point where I would like to use the file 'sparkline_tags.txt

1) If you are already using cumuluswebtags add the contents of sparkline_tags.txt to your cumuluswebtags.txt file.

2) If you have no existing webtags file, Save 'sparkline_tags.txt' and have Cumulus Process and Upload as sparkline_tags.php
In spark.php change the path to your webtags file.
FOR EXAMPLE:
include("/sparkline_tags.php");
OR
include($_SERVER["DOCUMENT_ROOT"] . "/cumulus/cumuluswebtags.php");
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

send me ur cuumulus location

in ur php /html put
<!DOCTYPE HTML>
<html>
<head>

<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="sparkline.min.js"></script>
<script type="text/javascript" src="spark.php"></script>


then where u want to put the graphics

<span class="temp"></span></td>

and so on

ps if it help look at mine

http://www.davisworthing.co.uk/new/one.php
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
mitmania
Posts: 37
Joined: Tue 07 Feb 2012 11:51 am
Weather Station: WS2350 & Davis VP2
Operating System: Win 7
Location: Italy
Contact:

Re: Sparklines

Post by mitmania »

hen this part of the modification of the index.htm file is clear to me ... it's the part of the configuration I do not understand
User avatar
dazza1223
Posts: 860
Joined: Sun 25 Jan 2015 8:41 pm
Weather Station: Davis Vantage Pro 2 plus
Operating System: Raspberry pi 4 (4gb)
Location: Worthing
Contact:

Re: Sparklines

Post by dazza1223 »

so u put cuumuluswebtagsT.txt in the cuumulus web folder this in cuumulus go to Extra web files


PROCESS cuumuluswebtagsT.txt REMOTE FILENAME cumuluswebtags.php
Have fun and keep learning

dazza :D

https://www.davisworthing.co.uk

Image
Post Reply