Jump to content

Recommended Posts

kiror    349

A table is a simple thing to implement in bbcode and may improve article quality because some information can be represented in a better way using tables.

This is an example of table generated with an online tool:

[table]
[tr]
  [th]Action[/th]
  [th]Person 1 likes doing it?[/th]
  [th]Person 2 likes doing it?[/th]
[/tr]
[tr]
  [td]Sleep[/td]
  [td]Yes[/td]
  [td]No[/td]
[/tr]
[tr]
  [td]Wakeup[/td]
  [td]No[/td]
  [td]Yes[/td]
[/tr]
[/table]

[spoiler=How that bbcode is rendered with actual forum code]

[table]

[tr]

[th]Action[/th]

[th]Person 1 likes doing it?[/th]

[th]Person 2 likes doing it?[/th]

[/tr]

[tr]

[td]Sleep[/td]

[td]Yes[/td]

[td]No[/td]

[/tr]

[tr]

[td]Wakeup[/td]

[td]No[/td]

[td]Yes[/td]

[/tr]

[/table]

 

 

An interesting thing about the implementation is that it does have correspondence "one to one", as you can see in the HTML below:

<table>
<tr>
  <th>Action</th>
  <th>Person 1 likes doing it?</th>
  <th>Person 2 likes doing it?</th>
</tr>
<tr>
  <td>Sleep</td>
  <td>Yes</td>
  <td>No</td>
</tr>
<tr>
  <td>Wakeup</td>
  <td>No</td>
  <td>Yes</td>
</tr>
</table>

Share this post


Link to post
Share on other sites
Shiro    437

Hello,

 

This is something I am looking into implementing. There are several ways to implement tables on Xenforo, and I am looking into implementing the one that would be easiest to use.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×