How To Work with tables in forum posts (Xenforo 2.0 - Jan 2019 onwards)

Remove this Banner Ad

Click the "table" button above the reply box to set the table dimensions.

tables-1.png

tables-2.png

You can go above the default maximum rows and columns by adding rows and columns after you add the table.

tables-3.png

You can align the text vertically and horizontally:

tables-4.png

And you can add a header:

tables-5.png


And there you are:
ThisIs TheHeader

This

Is

A

Table

Hi! Aligned to the bottom.

You can do
some things
with it

Text aligned to the top

Bold!

As you can see, the old table code doesn't work no more:

Old table code still works, and will be converted to the new table code if you edit the post and save it again:
hello! |old|table :(
\these| still |work
\until you|edit|the post.

BBCode won't work in cells in old tables. Not sure if it ever will as the software developer Xenforo changed the whole BBcode system.
 
Last edited:
  • Thread starter
  • Admin
  • #3
Hooray! Really appreciate this, thanks!
It took a lot of time - with the new Xenforo software about 2/3 of the old add-ons have been abandoned - including the old table add-on.

But the new one is much better IMO - we just had to wrestle with it to get it to play nicely with the old format.

As I said, edit and save any post with an old table in it and it will convert it over. Let us know if there are any problems.
 

Log in to remove this ad.

Test with Squiggle Predictor:






W

L

D

%

1.

Melbourne

18

4

0

141.6%

2.

Richmond

17

5

0

141.1%

3.

Adelaide

14

8

0

109.7%

4.

West Coast

13

9

0

119.5%

5.

Essendon

13

9

0

114.9%

6.

Geelong

13

9

0

114.8%

7.

Collingwood

13

9

0

108.4%

8.

GWS

12

10

0

113.3%

9.

Hawthorn

12

10

0

108.5%

10.

North Melbourne

12

10

0

99.2%

11.

Port Adelaide

11

11

0

105.5%

12.

Brisbane Lions

10

12

0

92.2%

13.

Sydney

9

13

0

100.0%

14.

Western Bulldogs

9

13

0

89.1%

15.

St Kilda

9

13

0

87.9%

16.

Fremantle

6

16

0

76.4%

17.

Gold Coast

4

18

0

57.4%

18.

Carlton

3

19

0

65.4%
 
Well thanks again!

I've had a play and haven't found any major problems. Just a few minor curiosities, just FYI:

It seems essential that the TR and TD tags be on the same line and also both be uppercased. Otherwise it's interpreted as a table with one cell. E.g. this doesn't work, even though it looks like it should:

Code:
[table]
[tr]
[td]
Hello!
[/td]
[/tr]
[/table]

But that will only bite people who will go in and mess around with the BBcode manually, and there aren't too many of us who do that.

From a cosmetic point of view, I think it'd be a little better without the "width:100%" on the table, since that can create some very spaced-out tables. The ladder above, for example, is somewhat hard to read on a wide desktop screen.

Similarly, it'd be good to lose the "width:" settings on each cell that forces columns to be the same width, which can produce sub-optimal results vs just letting browsers automatically reflow to fit to content. E.g. without that setting, this table would fit a lot better:


Team

Wins

Losses

Greater Western Sydney GIANTS or some other similarly long content

1

0

Tigers

0

1

Saints

0

0
 
  • Thread starter
  • Admin
  • #7
Well thanks again!

I've had a play and haven't found any major problems. Just a few minor curiosities, just FYI:

It seems essential that the TR and TD tags be on the same line and also both be uppercased. Otherwise it's interpreted as a table with one cell. E.g. this doesn't work, even though it looks like it should:

Code:
[table]
[tr]
[td]
Hello!
[/td]
[/tr]
[/table]

But that will only bite people who will go in and mess around with the BBcode manually, and there aren't too many of us who do that.

From a cosmetic point of view, I think it'd be a little better without the "width:100%" on the table, since that can create some very spaced-out tables. The ladder above, for example, is somewhat hard to read on a wide desktop screen.

Similarly, it'd be good to lose the "width:" settings on each cell that forces columns to be the same width, which can produce sub-optimal results vs just letting browsers automatically reflow to fit to content. E.g. without that setting, this table would fit a lot better:

Team

Wins

Losses

Greater Western Sydney GIANTS or some other similarly long content

1

0

Tigers

0

1

Saints

0

0

Thanks - will feedback to the developer.
 
Well thanks again!

I've had a play and haven't found any major problems. Just a few minor curiosities, just FYI:

It seems essential that the TR and TD tags be on the same line and also both be uppercased. Otherwise it's interpreted as a table with one cell. E.g. this doesn't work, even though it looks like it should:

Code:
[table]
[tr]
[td]
Hello!
[/td]
[/tr]
[/table]

But that will only bite people who will go in and mess around with the BBcode manually, and there aren't too many of us who do that.

From a cosmetic point of view, I think it'd be a little better without the "width:100%" on the table, since that can create some very spaced-out tables. The ladder above, for example, is somewhat hard to read on a wide desktop screen.

Similarly, it'd be good to lose the "width:" settings on each cell that forces columns to be the same width, which can produce sub-optimal results vs just letting browsers automatically reflow to fit to content. E.g. without that setting, this table would fit a lot better:

Team

Wins

Losses

Greater Western Sydney GIANTS or some other similarly long content

1

0

Tigers

0

1

Saints

0

0


Agree with all you've said, especially the width setting.

The only other thing I've noticed Chief is that with the new bb code for tables the character limit is hit a lot sooner than in the past as the old single character | and / to start a new column or row has been replaced by the tr and td format (4 characters each when including the brackets). That's a pretty minor thing though and can be worked around by splitting the table over separate posts.

Overall though tables are looking great and should be a lot easier for users to insert without bb code.
 
Please, please, help me! :(

I went to the BB codes, and I collected all the data, and then I entered all the codes, and it still looks like this! Where is my table????

Teams2018201720162015
Adelaide1-32-33-32-3
Brisbane0-31-30-30-3
GWS Giants2-32-31-32-3
Richmond2-33-31-32-3
West Coast2-32-32-31-3
Sydney2-30-3-32-3
 

(Log in to remove this ad.)

Please, please, help me! :(

I went to the BB codes, and I collected all the data, and then I entered all the codes, and it still looks like this! Where is my table????
I believe you've hit the spacing bug I mentioned earlier: You can't have any newlines between TR and TD/TH tags. When I remove those newlines from your table, it looks like this:

Teams2018201720162015
Adelaide1-32-33-32-3
Brisbane0-31-30-30-3
GWS Giants2-32-31-32-3
Richmond2-33-31-32-3
West Coast2-32-32-31-3
Sydney2-30-3-32-3
 
I've talked to the dev and he isn't doing any work on the version 2.0 code, so any issues we will have to patch up ourselves until we go to version 2.1.

We are also trying to manage the two types of table code so there could be little issues with the system deciding which is which.
 
Chief I may be going crazy, but I was editing a bunch of tables in resource posts yesterday/today and could have sworn that the alternate rows was working but now doesn't appear to be. It works in the editor itself but not in a post-preview or an actual post.

Col1Col2Col3Col4Col5
5005TestEven More TestHello
200455Also TestMore TestOk
 
Chief I may be going crazy, but I was editing a bunch of tables in resource posts yesterday/today and could have sworn that the alternate rows was working but now doesn't appear to be. It works in the editor itself but not in a post-preview or an actual post.

Col1Col2Col3Col4Col5
5005TestEven More TestHello
200455Also TestMore TestOk
Yeah that’s odd I will check it out
 

Remove this Banner Ad

Back
Top