Page 1 of 2

A Little Day / night Chart Revisited ...

Posted: Tue 08 Jan 2019 10:18 pm
by beteljuice
The betejuice has been playing with the 'little day night chart' and the banner style one.

To create a mouse-over 'pop-up' with legend. The only way to demonstrate is within a page, so .....
Here's a demo on a dummy site, but I've made it so that you can customise to your own requirements and download all the necessary / modified files :shock:

Demo / Configurater

The DEMO / 'configurator' should work with M$ IE, If you can't remember where you live it will take a best guess at lat / lon / city - once you have set anything it will remember you for a week, because you may be back to 'tweak'.

Recap:
  • You get TWO daylight hours graphics which can be used as stand-alones
    The code is customised for you so you don't need PHP / coding knowledge
    If you want a mouse-over popup you can put it where you want and the code is provided for you
    .... and so on ...
'tis a plaything and should be accepted as is ....

Re: A Little Day / night Chart Revisited ...

Posted: Mon 27 May 2019 11:49 pm
by Mapantz
Hi beteljuice

It seems there's no 'night time' on the chart. :lol:

Re: A Little Day / night Chart Revisited ...

Posted: Tue 28 May 2019 6:10 pm
by beteljuice
... It seems there's no 'night time' on the chart.
I wonder ...... could that possibly be because for the location viewed there is no "Astronomical Night" at this time of year :lol:

Re: A Little Day / night Chart Revisited ...

Posted: Tue 28 May 2019 10:46 pm
by Mapantz
I'm confused?!

The pie chart shows no section of night time despite there being 8 hours of it.

Re: A Little Day / night Chart Revisited ...

Posted: Wed 29 May 2019 7:20 am
by mcrossley
Screen capture required I think? I see dusk segments but no true night as the betejuice said.

Re: A Little Day / night Chart Revisited ...

Posted: Wed 29 May 2019 11:06 am
by Mapantz
2019-05-29 (2).png
Night time shows fine on Paul's website: http://www.komokaweather.com/

Re: A Little Day / night Chart Revisited ...

Posted: Wed 29 May 2019 11:25 am
by mcrossley
Ah! OK. It is as the beteljuice explained, we do not have any "nighttime" at UK latitudes near mid-summer, it is officially twilight all night as the Sun is not far enough below the horizon to count as "night".

Re: A Little Day / night Chart Revisited ...

Posted: Wed 29 May 2019 12:32 pm
by PaulMy
It is as the beteljuice explained, we do not have any "nighttime" at UK latitudes near mid-summer
NO nighttime??
When do the prowlers come out....

Enjoy,
Paul

Re: A Little Day / night Chart Revisited ...

Posted: Wed 29 May 2019 9:46 pm
by RayProudfoot
Paul,

Of course we have nighttime. It’s dark outside now. But as Mark has said at higher latitudes the sun does not drop below the horizon enough for twilight to change to proper darkness.

The sun has to be more than 18° below the horizon for full darkness and it doesn’t between late May and late July.

Re: A Little Day / night Chart Revisited ...

Posted: Wed 29 May 2019 10:30 pm
by RayProudfoot
I’m happy to be corrected but if you subtract 18 from 66° 34’ ( the Arctic and Antarctic circles) you get 48° 34’.

Anywhere in either hemisphere with a latitude lower than that will have proper darkness all year. Higher and you won’t.

Re: A Little Day / night Chart Revisited ...

Posted: Thu 30 May 2019 10:54 pm
by Mapantz
Thanks for the info.

I genuinely never knew that about astronomical twilight being from sunset to sunrise in certain latitudes. I understand twilight, and it can be seen. But, there's never been any hint of light on the horizon at this time of night leading up to the Summer solstice. I regularly go beach fishing at this time of year and by 11pm, it is complete darkness until there's some light beginning to show around 3am.

Re: A Little Day / night Chart Revisited ...

Posted: Thu 30 May 2019 11:16 pm
by RayProudfoot
You probably have to have studied astronomy at some stage to be able to recognise a truly dark sky. Sadly there are few places in the U.K. that are free of light pollution. I suspect it’s only in a truly dark area where you would be able to detect a twilight glow to the north at this time of year.

I don’t know your geographical area but if you have no urbanisation to the north you may be able to spot that glow. But more likely it would require a long exposure photo to reveal the light. Perhaps why it’s called astronomical twilight.

Re: A Little Day / night Chart Revisited ...

Posted: Fri 31 May 2019 7:00 am
by mcrossley
Having done a bit of amateur astronomy I can tell you that it really isn't dark at all at this time of the year. As Ray said you can see the glow from the Sun as it passes to the north. Indeed the whole sky is washed out, objects that are easily visible in the winter cannot be seen at all or with great difficulty in the summer due to the background brightness.

Stumbling around in the dark becomes a lot easier in the summer too! A lot less stumblely that is :lol:

For astronomers, the summer months in the UK are primarily restricted to observing the planets and Moon.

Re: A Little Day / night Chart Revisited ...

Posted: Mon 16 Mar 2020 6:38 pm
by sfws
I have recently updated from PHP 7.2 to PHP 7.3, I'm not aware of having changed anything else, but given I restarted using my Cumulus scripts after a long break, I can't be absolutely sure.
My little day night chart (it was very slightly edited from the one in this thread) was working but seems to have stopped generating a picture with the script unchanged (other than my latitude and longitude and the time of year) as I also tried restoring it from an old back up when the one I was using did not work. Although my script has error_reporting(E_ALL); in it, no error is being generated, so I have no idea where to start looking.
My web server is on my own PC and not viewable to others, so it may be different for anyone to help, but if anyone has a bright idea? Do you want me to zip up my script?

Re: A Little Day / night Chart Revisited ...

Posted: Mon 16 Mar 2020 7:20 pm
by saratogaWX
You can try doing a view-source on the local URL to the script .. it may show PHP error messages in it. I suspect that a Notice: type error message got in there somehow and is screwing up the image.
Also, you can put error_reporting(0); at the start of the script.. that would suppress any pesky text errata from showing and screwing up the image.