miniBB ® 

miniBB

®
Support Forums
  
 | Start | Register | Search | Statistics | File Bank | Manual |
Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /  
 

HTML Tables in posts

 
Author PeKa
Partaker
#1 | Posted: 7 Aug 2002 12:51 
Add

$pattern[6] = "/\[lrtable\](.+?)::(.+?)\[\/lrtable\]/s";
$replacement[6] = '<table><tr><td valign="top">\\1</td><td valign="top">\\2</td></tr></table>';

to bb_codes.php

Use it this way:
[lrtable]Left side::Right side[/lrtable]
Of course you can make "Left side" or "Right side" another lrtable ;-)

That may be not the most comfortable way for users, but maybe moderators want to give their postings a little extra flavour :-)

Author 4days
Champi0n
#2 | Posted: 7 Aug 2002 16:24 
nice one :)

Author PeKa
Partaker
#3 | Posted: 8 Aug 2002 13:12 
3 Oct 2006 06:16 - Attached on mergeing:
Tables BB code

You can even add width=xx to the first <td> tag for better formatting with

$pattern[7] = "/\[lrtable(=)?(\d{1,3})?\]
(.+?)::(.+?)\[\/lrtable\]/s";
$replacement[7] = '<table><tr><td valign="top" width=\\2>\\3</td><td valign="top">\\4</td></tr></table>';

[lrtable=60]Left side::Right side[/lrtable]
will produce a 60 pixels wide left column, while the other uses what it needs.

Maybe I'll rewrite this some day to support real tables, not only for left-right

Custom Tutorials and Modifications miniBB Support Forums / Custom Tutorials and Modifications /
 HTML Tables in posts
 Share Topic's Link

Your Reply Click this icon to move up to the quoted message


  ?
Post as a Guest, leaving the Password field blank. You could also enter a Guest name, if it's not taken by a member yet. Sign-in and post at once, or just sign-in, bypassing the message's text.


Before posting, make sure your message is compliant with forum rules; otherwise it could be locked or removed with no explanation.

 

 
miniBB Support Forums Powered by Forum Software miniBB ® Home  Features  Requirements  Demo  Download  Showcase  Gallery of Arts
Compiler  Premium Extensions  Premium Support  License  Contact Us
Check out the Captcha add-on: protect your miniBB-forums from the automated spam and flood.


  ⇑