Welcome to the Cumulus Support forum.

Latest Cumulus MX V4 release 4.4.2 (build 4085) - 12 March 2025

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

Legacy Cumulus 1 release 1.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

If you are posting a new Topic about an error or if you need help PLEASE read this first viewtopic.php?p=164080#p164080

Creating PHP Pages

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

Moderator: daj

magusperde
Posts: 28
Joined: Sun 01 Jul 2012 2:56 pm
Weather Station: Oregon Scientific WMR 180
Operating System: Windows 10
Location: Plymouth
Contact:

Creating PHP Pages

Post by magusperde »

I wonder if anyone knows how to get Cumulus to generate php pages instead of html when it uploads to my site? Has this already been done soemwhere and I've missed it in the forums? Any help appreciated - thanks!
Rob
-------------------------------------
http://www.plymouthweather.co.uk
http://www.thisengland.org
I thought I saw a light at the end of the tunnel, but it was just some bastard with a torch bringing me more work...
gemini06720
Posts: 1700
Joined: Mon 10 Aug 2009 10:16 pm
Weather Station: No weather station
Operating System: No operating system
Location: World...

Re: Creating PHP Pages

Post by gemini06720 »

Indeed, many of us have been using PHP to produce our web pages - rather than the 'standard' HTM (or HTML) pages that need to be processed by Cumulus before being uploaded.

With that said/written, you do not need to upload the pages/templates to the web site anymore. Let me explain... ;)

First, you have to make sure that your hosting server allows the use of PHP for web pages.

Second, the 'standard' 'HTM' templates have to be converted to PHP. Then the Cumulus Web Tags within those templates have to be converted to PHP webtags (or variables) that the PHP interpreter (on your hosting server) will convert to values just before sending the web page to the user's browser (such as the Cumulus Web Tag '<#time>' will need to be converted to '$time').

Have a look at the Php webtags Wiki page to get an idea of the PHP webtags and how they are used.

Then, once you have converted all the HML templates to the PHP format (and all the Cumulus Web Tags to their PHP webtags equivalent), only two data files (other than the graphic files) have to be uploaded to your hosting web server, the 'realtime.txt' and the 'cumuluswebtags.php' files.

Note: When I write about converting the HML templates to the PHP format, I do not mean that the templates have to be completely rewritten - just that their extensions have to be changed from '.htm' to '.php' and the Cumulus Web Tags replaced by their PHP webtags equivalent.

It is not that complicated and many of us, PHP converts will be happy to help you. :)

Oh, let me know if you undertake the conversion process and I will supply you with an up-to-date (all Web Tags) 'cumuluswebtags.txt' template.
magusperde
Posts: 28
Joined: Sun 01 Jul 2012 2:56 pm
Weather Station: Oregon Scientific WMR 180
Operating System: Windows 10
Location: Plymouth
Contact:

Re: Creating PHP Pages

Post by magusperde »

Hey Gemini,

Thanks for that detail, concise and informative. It produced a bit of a "slap the forehead and say duh" moment for me! I'll play around with it over the coming week when I get an hour or two just to see what I can come up with and I would very much appreciate an up to date 'cumuluswebtags.txt' template. Do you know if there is a "share your website" thread on these forums anywhere? It would be very useful to see what others have done with Cumulus...

Cheers!
Rob
-------------------------------------
http://www.plymouthweather.co.uk
http://www.thisengland.org
I thought I saw a light at the end of the tunnel, but it was just some bastard with a torch bringing me more work...
User avatar
steve
Cumulus Author
Posts: 26672
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Creating PHP Pages

Post by steve »

magusperde wrote:Do you know if there is a "share your website" thread on these forums anywhere? It would be very useful to see what others have done with Cumulus...
There's the user map, currently with 873 stations on it, and many people have links to their sites in every post they make. If anyone has anything specific they want to "show off" they would normally post about in this part of the forum. The 'third party tools' part of the forum has various offerings that people have created, as does the downloads page.
Steve
magusperde
Posts: 28
Joined: Sun 01 Jul 2012 2:56 pm
Weather Station: Oregon Scientific WMR 180
Operating System: Windows 10
Location: Plymouth
Contact:

Re: Creating PHP Pages

Post by magusperde »

Thanks Steve. I've added my site to the map and made a donation to you for my use of Cumulus. I wonder how many people actually donate? ;)
Rob
-------------------------------------
http://www.plymouthweather.co.uk
http://www.thisengland.org
I thought I saw a light at the end of the tunnel, but it was just some bastard with a torch bringing me more work...
ColinJS
Posts: 18
Joined: Wed 09 Feb 2011 10:21 am
Weather Station: Maplin N96GY
Operating System: Windows XP
Location: Brentwood, Essex
Contact:

Re: Creating PHP Pages

Post by ColinJS »

'Duh moment' is right, but you're not alone. I had put off doing this too, thinking that I'd have to add all the new pages to the ftp and other messing about.

But of course it isn't necessary, that's the whole idea. Duh! So I'll be getting down to it this week too.

Thanks for waking me up guys.

Colin
duke

Re: Creating PHP Pages

Post by duke »

Here's a thread I stared a while ago when I was "diving in" :)
magusperde
Posts: 28
Joined: Sun 01 Jul 2012 2:56 pm
Weather Station: Oregon Scientific WMR 180
Operating System: Windows 10
Location: Plymouth
Contact:

Re: Creating PHP Pages

Post by magusperde »

Useful indeed - thanks Duke!
Rob
-------------------------------------
http://www.plymouthweather.co.uk
http://www.thisengland.org
I thought I saw a light at the end of the tunnel, but it was just some bastard with a torch bringing me more work...
gemini06720
Posts: 1700
Joined: Mon 10 Aug 2009 10:16 pm
Weather Station: No weather station
Operating System: No operating system
Location: World...

Re: Creating PHP Pages

Post by gemini06720 »

Over the past days, I have been 'playing' around with the 'standard' templates and I came up with some 'interesting' all-PHP templates matching (as closely as I could) the 'standard' Cumulus templates - the one I now have online at Tzouhalem-Maple Bay Weather have been adapted (read, slightly modified) to properly access all the required files within my directory tree structure.

I had to make some modification to the display of the page menus as, with the number of items (links) now available, the display varied greatly between browsers - thus the present look of the menus that displays properly in all browsers.

Four static templates are required to produce each pages ... with PHP, the integration of the 4 templates is almost seamless as all the code is compiled together on the hosting server (to create one full complete file) before the resulting page is downloaded into the user's browser's cache and displayed on the user's browser's screen.

For the [link removed] pages, other than the 4 static templates, three Cumulus-processed templates are used - two 'near real time produced' templates, the 'cumuluswebtags.php' and the 'realtime.txt' templates and one 'regularly produced', the 'cumulusXwebtags.php' used for the monthly records page.

If there is enough 'serious' interest, I might let myself getting involved in a tutorial...

Would also be nice if the PHP template could eventually be included into the Cumulus package ... one can only hope...
Last edited by gemini06720 on Sun 09 Jun 2013 7:07 am, edited 1 time in total.
User avatar
steve
Cumulus Author
Posts: 26672
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Creating PHP Pages

Post by steve »

gemini06720 wrote:Would also be nice if the PHP template could eventually be included into the Cumulus package ... one can only hope... :mrgreen:
I would be very happy to include a PHP version of the standard web site with Cumulus, or at least include it on the downloads page, if someone were to offer such a package and commit to maintaining it ;)
Steve
OliII
Posts: 54
Joined: Mon 19 Mar 2012 11:47 am
Weather Station: WMR 200 by Oregon Scientific
Operating System: WinXP SP3
Location: Belgium

Re: Creating PHP Pages

Post by OliII »

I'm using cumuluswebtags.php to make my own php pages but with phpBB3 templating script.
At this time, i try two ways to make these pages :
- Importing datas from cumuluswebtags.php into my SQL database and persorming SQL request from phpbb3 pages
- Using cumuluswebtags.php with ph recquire() function fro php strict pages.

My knowledge on php is not very important.. but if someone want help to make the package, i can provide mine. I better know phpBB3 script and templates.
Image
http://www.7331.be/meteo website based on the phpBB3 forum and template. WMR200 + UVN 800 - Cumulus 1.9.4 1062 / Windows XP Service Pack 3 build 2600 FR
gemini06720
Posts: 1700
Joined: Mon 10 Aug 2009 10:16 pm
Weather Station: No weather station
Operating System: No operating system
Location: World...

Re: Creating PHP Pages

Post by gemini06720 »

Steve, it would be certainly nice if both file formats (HTM and PHP) were available within one package... :mrgreen:

As for maintaining the PHP templates ... it is no more difficult to maintain the PHP templates as it is to maintain the HTM templates ... as I indicated, the PHP templates are completely static - once extracted from the package, the PHP templates just need to be uploaded to the hosting server without further processing - only two data templates need to be processed by Cumulus.

The PHP templates have been designed so that similar (repeating) information, such as the W3C header, the menus (links) and the W3C footer have their own templates - the code for the data appearing on the screen has its own template, very similar to the 'standard' HTM templates.
gemini06720
Posts: 1700
Joined: Mon 10 Aug 2009 10:16 pm
Weather Station: No weather station
Operating System: No operating system
Location: World...

Re: Creating PHP Pages

Post by gemini06720 »

OliII wrote:...with phpBB3 templating script.
Are you writing about the phpBB3styles templates? Are those not for the phpBB open source bulletin board system? :shock:

Please correct me if I am wrong. ;)
OliII
Posts: 54
Joined: Mon 19 Mar 2012 11:47 am
Weather Station: WMR 200 by Oregon Scientific
Operating System: WinXP SP3
Location: Belgium

Re: Creating PHP Pages

Post by OliII »

Yes, phpBB is free and Open Source forum software.
phpbb-fr boards in france help to make personnal pages and never getting problems with it. All they need is the copyright into the pages and the source.
Image
http://www.7331.be/meteo website based on the phpBB3 forum and template. WMR200 + UVN 800 - Cumulus 1.9.4 1062 / Windows XP Service Pack 3 build 2600 FR
gemini06720
Posts: 1700
Joined: Mon 10 Aug 2009 10:16 pm
Weather Station: No weather station
Operating System: No operating system
Location: World...

Re: Creating PHP Pages

Post by gemini06720 »

But, but... installing, modifying and up-keeping an open source bulletin board system modified to display weather information is not something I would recommend for any user (certainly not the majority of the Cumulus users)! :roll:

I have many of those blog, bulletin board, content management software installed on my home server (such as CMS Made Simple, DokuWiki, Drupal, FUDforum, Joomla!, MediaWiki, MyBB, phpBB3, Simple PHP Blog, SMF2, Tiki Wiki CMS, WordPress and YaBB) but would certainly not start a tutorial on their installation, setting up and maintenance... :twisted:

The concept proposed in this thread is/was to adopt/convert the 'standard' templates provided (installed) by Cumulus to the PHP format thus reducing the number of templates processed by Cumulus.
Post Reply