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

htm to php

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

Moderator: daj

Post Reply
NoDoze
Posts: 2
Joined: Mon 31 Dec 2012 7:16 am
Weather Station: Ambient
Operating System: Win 8
Location: Seattle

htm to php

Post by NoDoze »

For example how would I convert the index.htm file to index.php?

Cumulus 1.9.4 Build 1099

I search the forums but couldn't find any info on how to. However, I see other templates using php, so there should be a way, no?

Is this the way I'm supposed to do it?
Configuration/Internet/Internet Settings/Files
Local File Name: C:\Cumulus\web\index.htm
Remote File Name: index.php
It creates the index.htmtmp file, but index.htm uploads only.

I'm a PHP developer and want to include other variables, etc to the files, but of course the files need to be .php in order to work.

Any insight, direction, help appreciated.

Thank you
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: htm to php

Post by water01 »

Use this article in the WiKi

http://wiki.sandaysoft.com/a/Php_webtags

Once you have implemented the one upload of cumuluswebtags.txt to cumuluswebtags.php you can stop the upload of the standard .htm files and alter all the code to use the php webtags as described in the Wiki.
David
Image
User avatar
saratogaWX
Posts: 1170
Joined: Wed 06 May 2009 5:02 am
Weather Station: Davis Vantage Pro Plus
Operating System: Windows 10 Professional
Location: Saratoga, CA, USA
Contact:

Re: htm to php

Post by saratogaWX »

Something to keep in mind... a PHP page is just an HTML page with embedded PHP markup, otherwise, it's no different. You can take a HTML page and just change it's extension to .php and it will display the same without any PHP markup embedded. So just rename your index.htm to index.php and it will work the same as now, and you can add <?php ... ?> markup as you like.
User avatar
PaulMy
Posts: 3777
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

Re: htm to php

Post by PaulMy »

If you don't want the index.htm page to be uploaded you need to uncheck the Internet - Files - Include Standard Files. And then add in to the Configuration - Internet - Files - all the /web/xxxxT.htm files such as todayT.htm, gaugesT.htm, etc. and add those files for Cumulus processing and upload, but do not add the indexT.htm. Then also add there your indexT.php that you are modifying, or whatever you may call it, for Cumulus processing and upload as index.php.

There may be other ways but I know this works.

Enjoy,
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm

Image
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: htm to php

Post by water01 »

Paul, not sure where you got this information, but once all the standard pages have been converted to .php as per the Wiki the only file that requires uploading is the processed cumuluswebtags.txt renaming it cumuluswebtags.php. Each of the converted standard pages has an include for cumuluswebtags.php, and when the page loads if the pages have been altered correctly they will automatically load the value of the tag from cumuluswebtags.php to the appropriate field in the altered code.

You do not need any of the xxxxxxT.htm files uploaded as they will already be on the server as xxxxxxx.php (i.e. index.php (main Page), thismonth.php etc.) and will be processed by the php server when the code is executed. Take a look at the Wiki, it is slightly longer to implement but by far the easiest once it has been done.
David
Image
User avatar
PaulMy
Posts: 3777
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

Re: htm to php

Post by PaulMy »

I was not thinking of all the T files to be .php just the index. Looks like I understood, sorry.

Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm

Image
Post Reply