vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   BB Code Enhancements - BB Code [table] (https://vborg.vbsupport.ru/showthread.php?t=107985)

Detomah 02-19-2006 01:13 AM

If this is as good as it looks and I think it is, one of the admins on my site is going to love you forever. Although I can see a lot of thread editing going on to update all the old one's done using the other table code I had installed.

/me uninstalls a less well made version of a table code and gets ready to install this version.

Detomah 02-19-2006 04:36 PM

Could you possibly do an example table, using pretty much every formatting function available as an example please. My admins are having a bit of trouble trying to do certain tasks.

Aslo, would there be any chance of making it so you can actually doing the following:

1. Have a code to allow you to choose the cell class alt1 or alt2 instead of it being automatically alternating.
2. Make it so we can use tcat or thead for the header cells.
3. Make it so we can merge cells.

If they are already possible and i'm missing it, could you give me an example of how they work.

StGaensler 02-19-2006 05:10 PM

Do you mean formating options of my vBCode or generally formatting (with vBulletin vBCode)? I am already using every (included) formating option in my example table in the first and second picture.

1. + 3. This would require some time of work - time I don't really have. I add these things on the feature list for the next version but I can not promise when I can release it.
2. My vBCode already uses thead for the header cells. This is the source code of the table in the attachment:
HTML Code:

<table class="stg_table tborder" style="width: 15em;"><thead class="thead"><tr><th>rank</th><th>name</th><th>age</th><th>points</th></tr></thead><tbody><tr class="alt1"><td>1</td><td>
Marvin</td><td>28</td><td>482</td></tr><tr class="alt2"><td>2</td><td>
Nadja</td><td>30</td><td>300</td></tr><tr class="alt1"><td>3</td><td>
Nicky</td><td>34</td><td>300</td></tr><tr class="alt2"><td>4</td><td>
Henry</td><td>46</td><td>298</td></tr><tr class="alt1"><td>5</td><td>
Nadja</td><td>12</td><td>85</td></tr><tr class="alt2"><td>6</td><td>
Tom</td><td>56</td><td>-</td></tr></tbody></table>

You only have to "say" that there is a header: [table=head] .... [/table]
Or didn't I get your question?

mkdevo 02-28-2006 05:08 PM

is there any way to merge cells? say i want to have a 2-column table, and i want something centered across 2 cells for the header cell - is that possible?

EDIT - whoops, just noticed that was #3 in the post 2 above mine, though it wasn't answered...

StGaensler 02-28-2006 09:31 PM

It was much work but I have tried it:
Here is a new version supporting colspans!

BUT this is a beta version!
You can try this version but use it on your own risk!
Currently colspan is not supported in WYSIWYG-Editor so the plain code is displayed

To add a colspan to a cell simply write {colsp=X} at the beginning of the cell. X is the number of cells the cell should be big.

If you find bugs please report them here.

Good night :) (I'll go to bed now)
Stefan

Edit: I wrote a better version than yesterday so I edited my post :D
The bugs mentioned before have been taken out :)

There is only one thing to consider when using colspan and sort: Cells "behind" the colspan are internally filled with "!!!colspan" and can be sorted as every other cell.

EDIT: removed attachment (4 views) - new version is out: post #915835

mkdevo 03-01-2006 02:00 PM

StGaensler - thanks for your continued support with this hack! i'm currently testing out the beta. just wanted to let you know about a small problem i ran into:

i'm testing out the colspan on the header row. i want the header row to be centered. if i use the center BBCode, it messes up the table. however, if i use the center html code, it works.

to show you what i mean, this does NOT work:

HTML Code:

[table=head; width=100%]{colsp=2}[CENTER][b]1999[/b] [i](6 shows)[/i][/CENTER]
this DOES work:

HTML Code:

[table=head; width=100%]{colsp=2}<CENTER>[b]1999[/b] [i](6 shows)[/i]</CENTER>

mkdevo 03-01-2006 02:08 PM

also, you've described how to define table width. is there a way to define cell width?

StGaensler 03-01-2006 02:46 PM

1 Attachment(s)
Thanks for the feedback but I can't reproduce it.
Code I used:
HTML Code:

[table=head; width=20%]{colsp=2}[center][B]1999[/B] [I](6 shows)[/I][/center]
test 1|test 2
test 1|test 2
test 1|test 2[/table]

Result -> attachment
Could you give me a full example of the table or an account on your board so I can test it there?

No currently there is no possibility to define cell/column width, I added it to the list.

mkdevo 03-01-2006 02:59 PM

1 Attachment(s)
Quote:

Originally Posted by StGaensler
Thanks for the feedback but I can't reproduce it.
Code I used:
HTML Code:

[table=head; width=20%]{colsp=2}[center][B]1999[/B] [I](6 shows)[/I][/center]
test 1|test 2
test 1|test 2
test 1|test 2[/table]

Result -> attachment
Could you give me a full example of the table or an account on your board so I can test it there?

interesting. using the exact code you have above, you can see my result in the attachment:

mkdevo 03-01-2006 03:02 PM

i figured out a workaround to make it work, but i need to add an extra line break after the header:

HTML Code:

[table=head; width=20%]{colsp=2}[center][B]1999[/B] [I](6 shows)[/I][/center]

test 1|test 2
test 1|test 2
test 1|test 2[/table]

i wonder why that is...


All times are GMT. The time now is 05:06 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03605 seconds
  • Memory Usage 1,753KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_html_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete