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)

War.Frog 10-21-2009 12:54 PM

1 Attachment(s)
O.k. figured it out. Wow, it had nothing to do with Excel in this case. I found that this hack (or perhaps vBulletin) handles certain BB codes differently. For instance, if [center] is the primary modifier to a cell (the outside modifier) in addition to other codes, this hack goes haywire even though VISIBLY the code appears to be correct.

For instance:

[ center ] [ b ] TEST [ /b ] [ /center ] causes this hack grief.

Making the alignment tags the innermost modifiers fixes it:

[ b ] [ center ] TEST [ /center ] [ /b ]

I just moved the alignment tag adds to the beginning of the loop - I would suggest it's a problem you may run into too Bruno since it appears vBulletin is doing the rendering funny business.

Code:

For Each rngCell In rngRow.Cells
  c = c + 1
  sCell = rngCell.Text
  sFont = rngCell.Font.Name
           
  'If cell text is right aligned, add the [right] tag
  If rngCell.HorizontalAlignment = xlRight Then
    sCell ...
  End If
           
  'If cell text is centered, add the [center] tag
  If rngCell.HorizontalAlignment = xlCenter Then
      sCell = ...
  End If

Fix attached:

BRotondi 10-21-2009 07:15 PM

:) :eek: :rolleyes: and some others...

Thanks for the Update! ... and good night, 10:13 PM here ...

Greetings, Bruno

War.Frog 10-22-2009 02:34 AM

1 Attachment(s)
Someone earlier in this thread asked what outside-the-box things people are doing with their tables.

Just for "fun" to demonstrate how one can begin creating some very complex tables, I did a 19x25 table using four different 16x16 px squares...just three different shades (black, dark grey, light grey) and a white square.

Using BB Table Maker 2.2.xls, I was able to create this image. I can't imaging trying to do this manually. :D

MagicThemeParks 10-22-2009 10:24 AM

LOL...that's great War.Frog! :D

I want to try to do that to make a Mickey Mouse head! :up:

Ads1980 10-22-2009 11:58 AM

HI guys, do you know how I can add a background image so it's behind the table?

should I do a table within a table maybe that works? I'll test and report back

Cheers,
Ads

Ads1980 10-22-2009 12:30 PM

hmm nope that didn't work so I guessed next move was css.... can't get that to work either here's what I have so far:

css in the following area:
css=myclass
Defines the aditional css class of the whole table. Possible values have to be defined in admincp.
The value is prepended by stg_table_ so the resulting css class with above example would be stg_table_myclass
The css code has to be added to "Additional CSS Definitions" of your style (AdminCP -> Styles & Templates -> Style Manager -> (Dropdown) Main CSS -> Additional CSS Definitions)

a quick warning about the style below, I've added a png transparency so the table shows up better on my image, IE doesn't support this! I've tried various ways of getting around this but I've not been successful yet I'll keep you posted

Code:

/* ***** table styles ***** */

.stg_table_myclass {
background-image: url(http://www.gamersdomain.net/images/games/forza3/forza3banner_1.jpg);
background-repeat: none;
}

.stg_table_myclass td {
border: none;
background:transparent;
text-align: center;
}

.stg_table_myclass .alt1 {background-image: url(http://www.gamersdomain.net/images/transpancy.png); background: -ms-filter: “progid:DXImageTransform.Microsoft.Alpha(Opacity=90)”;
filter: alpha(opacity=90);
-khtml-opacity: 0.9;
-moz-opacity: 0.9;
opacity: 0.9;
}

.stg_table_myclass .alt2 {
background-image: url(http://www.gamersdomain.net/images/transpancy.png);
background: -ms-filter: “progid:DXImageTransform.Microsoft.Alpha(Opacity=70)”;
filter: alpha(opacity=70);
-khtml-opacity: 0.7;
-moz-opacity: 0.7;
opacity: 0.7;
}

/* ***** end of table styles ***** */

BB Code [table] Settings: CSS Classes For The Table
Code:

myclass
table:
Code:

[table="css=myclass;width=100%"]testcol11|testcol21|testcol31
testcol12|testcol22|testcol32
testcol13|testcol23|testcol33
testcol14|testcol24|testcol34[/table]

ok figured it out :) forgot the . in front of my style doh!

trotskid 10-24-2009 05:52 PM

Quote:

Originally Posted by trotskid (Post 1902478)
Hi. If sort a column of numbers with "." or "," (Project column), the values does not sort properly. For example:

30,274,388 will post higher than 101,274,388 (3>1).

How can I fix that with the current code?

Thank you


http://img195.imageshack.us/img195/365/tableen.jpg

PHP Code:

[table="head;sort=2d;autonum=1;autonumtitle=Rank;width=65%"]xxxx|Project|Points|P/day|National

test1
|30,274,388|68,520|60|3|

test2|101,274,388|50,956|80|2|

test3|20,274,388|21,325|29|6|

[/
table


Bump

jmpa 10-27-2009 05:50 PM

Now all we need is an html <table> to bb table converter!

BRotondi 10-27-2009 06:37 PM

@trotskid: I think, no one has the time yet to repair this... Often it's more complicated to solve it, than it seems. So it's up to you to get into the code or find a workaround (a leading 0? in background color? ...)

Bruno

War.Frog 10-28-2009 07:16 PM

Quote:

Originally Posted by jmpa (Post 1907052)
Now all we need is an html <table> to bb table converter!

I would think you could pseudo pull this off by copying the html table from the web page and pasting it into Excel, then using the content in the converter.


All times are GMT. The time now is 09:01 PM.

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.01979 seconds
  • Memory Usage 1,756KB
  • 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
  • (4)bbcode_code_printable
  • (1)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)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