Page 1 of 1

HELP!!! Autoredirect from http to https

Posted: Tue Jan 02, 2024 3:01 am
by riteoh
Firstly, I don't understand any of these http, or https references - I simply follow instructions and do what they say, with a bit of googling.

So the problem is that my page when I try and load as http://eyesontheweather.com.au automatically redirects to https://eyesontheweather.com.au

Googling how to stop this comes up with instructions on Deleteing domain security policies (didn't work) or changing site permissons (also didn't work).

This all seemed to start working when my hosting was renewed along with an SSL Certificate (again, which I don't know if I need). Coincidence perhaps - but I would have no idea!!

Does anybody know if there is a way to fix this? ANY way??

Thanks from somebody who knows little....

Re: HELP!!! Autoredirect from http to https

Posted: Tue Jan 02, 2024 9:10 am
by davidefa
Yes this is due to the 'automatic http to https redirection' enabled by your hosting provider.
For the main setup of meteotemplate, you have only to change the 'page URL' setting from

Code: Select all

http://www.eyesontheweather.com.au
to

Code: Select all

https://www.eyesontheweather.com.au
( you have only to add the 's' to the initial http )

Forgot to add, that according to my experience, also

Code: Select all

//www.eyesontheweather.com.au
works for both http and https sites ( but YMMV )

( if you are unable to access the main setup, you can do the same editing directly the config.php file, near line 21 edit the $pageURL variable value, consider that this file is 'vital' for meteotemplate and messing with it is not a good idea, so a backup could be advisable )


P.S.
Also consider that now 'all your contents should be https' ( images, external contents included in your pages... ).
This means that if you have a webcam on an 'http url' this won't be visible any more, by default ( unless you enable the 'mixed content loading' option in your browser, but then only visitors with this option enabled will be able to see these 'mixed content' )

main_setup1.png
main_setup1.png (182 KiB) Viewed 10234 times

Re: HELP!!! Autoredirect from http to https

Posted: Tue Jan 02, 2024 10:16 am
by meteoesine
I didn't know this to also add the www
however, if add it, it is curious to encounter problems displaying the liquidGauge in the rain block (only from a mobile phone) and in the rainSeason page, maybe also elsewhere
https://meteoesine.it/template/pages/st ... easons.php

Re: HELP!!! Autoredirect from http to https

Posted: Tue Jan 02, 2024 11:39 am
by riteoh
Thanks to davidefa - that has now solved problem one - the webpage loads with correct formats, and looks normal - however station is now showing as being offline for last couple of days.

Not sure if anybody here uses the same upload method to here to help me troubleshoot.

My station is a Davis Vantage Pro 2, with data retrieved via a wifi data logger. The data is then (sent?/received?) in Cumulus MX, which is running on a Raspberry Pi.

Meteotemplate then receives the data from Cumulus using a Cron Job.

Both the Raspberry Pi, and Data Logger are connected to my router - ticks there.
Cumulus shows that data has been recorded at all times during this period
Cron Job tested - and is running.

Yet no data seems to be uploaded to the site.

Usually when this happens, either the cron job has failed, or the pi has 'dropped' from the network - but all is showing as being OK there.

Any ideas on areas to troubleshoot further?

Re: HELP!!! Autoredirect from http to https

Posted: Tue Jan 02, 2024 4:03 pm
by davidefa
Update also the cron job on the raspberry to upload to the 'https site'.
( Uploading to the 'http site' should result in a '302 page redirect/moved permanently' which should be treated correctly by your raspberry, if not the cron job will fail )
Also verify the log of the cron job ( if available ) if contains any useful error/warning message.


P.S.
Your cache/apiLog.txt shows that the cron job ( that executes update/update.php ) is run correctly every minute, but the realtime.txt is not updated and contains stale data ( 2023-12-30 17:38:29 ).
So the issue should be in the 'cron job' that uploads the realtime.txt to your template site.

apiLog01.png
apiLog01.png (107.5 KiB) Viewed 10210 times

Re: HELP!!! Autoredirect from http to https

Posted: Tue Jan 02, 2024 4:24 pm
by davidefa
@meteoesine

The 'www' is not mandatory it depends on the dns configuration ( I think ).
So if it works without 'www' no need to add.

Re: HELP!!! Autoredirect from http to https

Posted: Wed Jan 03, 2024 2:32 am
by riteoh
Thanks again davidefa - I am learning!!

Updated the cron job, which now shows

https://www.eyesontheweather.com.au/tem ... ?password=******

Cron job log shows it is executing correctly, with no errors.

No update to the site still.

Using the little brain power that I have, I have double checked my Cumulus settings.

For some reason, it appears that the FTP file upload from Cumulus is not working - despite changing passwords, creating another FTP account, and testing that these both work in FileZilla before changing my Cumulus settings.

I have posted on the Cumulus Forum to see if somebody there can suggest why my files are not being uploaded.

[solved] HELP!!! Autoredirect from http to https

Posted: Wed Jan 03, 2024 11:23 am
by riteoh
Hi all.

Thanks for everybody's help.

The problem has been solved. Strangely, I had to change my host name from

eyesontheweather.com.au to ftp.eyesontheweather.com.au

Once this was changed, all files once again started uploading with their beautiful data!!