Welcome to the Cumulus Support forum.

Latest Cumulus MX release v3.4.6 (build 3070) - 23 March 2020
Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014

See the Wiki for downloading either version.

Include of a table

Discussion of Ken True's web site templates

Moderator: saratogaWX

Post Reply
User avatar
HansR
Posts: 636
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: Davis Vantage Pro 2+
Operating System: Raspbian GNU/Linux 10 (Buster)
Location: Wagenborgen (NL)
Contact:

Include of a table

Post by HansR » Tue 20 Aug 2019 7:48 pm

I use the wxnewpage template and add an include line for a text-file which contains two tables.
See code below. The result is here. As you can see, it displays, but not as intended (I want it displayed according to table style as you can see in the txt file).
In another situation (and here also) I can simply display a table and it works as wanted and expected.

So, what is happening with my pwsFWI.txt file?

Code: Select all

<div id="main-copy">
  
	<h1><?php langtrans('Sample Blank Page'); ?></h1>
    
    <p>This is a sample page</p>

<?php include('pwsFWI.txt');?>


    <p>Copy it to a new name and use as the base for a new page on your site.</p>
    
</div><!-- end main-copy -->
https://meteo-wagenborgen.nl / Cumulus (3.4.3 b3067)
Davis Vantage Pro 2+ / Raspberry Pi 3 Model B Plus Rev 1.3
Raspbian GNU/Linux 10 (buster) / 4.19.97-v7+ armv7l
Mono JIT compiler version 6.8.0.105 (tarball Tue Feb 4 21:51:48 UTC 2020)

User avatar
beteljuice
Posts: 2877
Joined: Tue 09 Dec 2008 1:37 pm
Weather Station: None !
Operating System: ex XP SP3 - now W10 laptop grr
Location: Dudley, West Midlands, UK

Re: Include of a table

Post by beteljuice » Tue 20 Aug 2019 8:48 pm

Your content is below the footer !
Image
......................Imagine, what you will KNOW tomorrow !

User avatar
HansR
Posts: 636
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: Davis Vantage Pro 2+
Operating System: Raspbian GNU/Linux 10 (Buster)
Location: Wagenborgen (NL)
Contact:

Re: Include of a table

Post by HansR » Wed 21 Aug 2019 2:40 am

beteljuice wrote:
Tue 20 Aug 2019 8:48 pm
Your content is below the footer !
I noticed that, thats why my message, because i definitely did not put it there and as you can see in my code, the include is in the main section. So how does it end up below the footer?

Best,
https://meteo-wagenborgen.nl / Cumulus (3.4.3 b3067)
Davis Vantage Pro 2+ / Raspberry Pi 3 Model B Plus Rev 1.3
Raspbian GNU/Linux 10 (buster) / 4.19.97-v7+ armv7l
Mono JIT compiler version 6.8.0.105 (tarball Tue Feb 4 21:51:48 UTC 2020)

User avatar
beteljuice
Posts: 2877
Joined: Tue 09 Dec 2008 1:37 pm
Weather Station: None !
Operating System: ex XP SP3 - now W10 laptop grr
Location: Dudley, West Midlands, UK

Re: Include of a table

Post by beteljuice » Wed 21 Aug 2019 2:48 am

Ah ...

NO closing </table> ;)
Image
......................Imagine, what you will KNOW tomorrow !

User avatar
HansR
Posts: 636
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: Davis Vantage Pro 2+
Operating System: Raspbian GNU/Linux 10 (Buster)
Location: Wagenborgen (NL)
Contact:

Re: Include of a table

Post by HansR » Wed 21 Aug 2019 2:55 am

Ai... :oops:
https://meteo-wagenborgen.nl / Cumulus (3.4.3 b3067)
Davis Vantage Pro 2+ / Raspberry Pi 3 Model B Plus Rev 1.3
Raspbian GNU/Linux 10 (buster) / 4.19.97-v7+ armv7l
Mono JIT compiler version 6.8.0.105 (tarball Tue Feb 4 21:51:48 UTC 2020)

User avatar
HansR
Posts: 636
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: Davis Vantage Pro 2+
Operating System: Raspbian GNU/Linux 10 (Buster)
Location: Wagenborgen (NL)
Contact:

Re: Include of a table

Post by HansR » Wed 21 Aug 2019 12:02 pm

But having corrected that, see page here, I still do not understand why I can not center (or justify) the table and the colored indicators (div's). The included code is pwsFWI.txt and you find it here. I want the tables centered on the <div id=main-copy> and the texts in the <TD> blocks centered as well. neither style nor old format align works. Any suggestions.

Best,
https://meteo-wagenborgen.nl / Cumulus (3.4.3 b3067)
Davis Vantage Pro 2+ / Raspberry Pi 3 Model B Plus Rev 1.3
Raspbian GNU/Linux 10 (buster) / 4.19.97-v7+ armv7l
Mono JIT compiler version 6.8.0.105 (tarball Tue Feb 4 21:51:48 UTC 2020)

Mapantz
Posts: 675
Joined: Sat 17 Dec 2011 11:55 am
Weather Station: Davis Vantage Pro2
Operating System: Windows 10 x64
Location: Dorset - UK
Contact:

Re: Include of a table

Post by Mapantz » Wed 21 Aug 2019 1:21 pm

Try changing the main table width to 100%

or..

Code: Select all

<table style="width:80%; margin-left:auto; margin-right:auto; border-collapse: collapse; background-color: #d7d7d7;"></tbody>
Image

User avatar
HansR
Posts: 636
Joined: Sat 20 Oct 2012 6:53 am
Weather Station: Davis Vantage Pro 2+
Operating System: Raspbian GNU/Linux 10 (Buster)
Location: Wagenborgen (NL)
Contact:

Re: Include of a table

Post by HansR » Wed 21 Aug 2019 2:25 pm

Yes, the second solution of the margin-auto works.
But that leaves the question with about the align:center style?
Anyway, problem solved. Thnx.

Best,
https://meteo-wagenborgen.nl / Cumulus (3.4.3 b3067)
Davis Vantage Pro 2+ / Raspberry Pi 3 Model B Plus Rev 1.3
Raspbian GNU/Linux 10 (buster) / 4.19.97-v7+ armv7l
Mono JIT compiler version 6.8.0.105 (tarball Tue Feb 4 21:51:48 UTC 2020)

Post Reply