BB Code [table] - Webmaster Forum
  #1  
Alt 09 Ekim 2021, 15:09:23
vBulletin - ait Kullanıcı Resmi (Avatar)
Süper Moderatör
 
İstanbul Şubesi
Üyelik Tarihi: 03 Haziran 2004
Mesajlar: 724
Konular: 368
Aldığı Beğeni: 0
Verdiği Beğeni: 0
Standart BB Code [table]

BB Code [table]

Description
This Hack provides a BB code [table] to add a table to the post
The skin of the table automatically fits the style because the CSS classes of vBulletin are used.

A table is simply made of some lines (will be the rows). The cols are seperated by |. So this will be a table:


Kod:
[table="head"]head col1|head col2|head col3 row1 col1|row1 col2|row1 col3 row2 col1|row2 col2|row2 col3[/table]
A screenshot of a "ready" table is attached

Usage
  1. install attached product XML through product manager (overwrite existing)
  2. install at least one language pack in AdminCP -> Languages & Phrases -> Download / Upload Languages -> Import Language XML File
    Important: Select the language you want to import the phrases into, not "(Create New Language)" - this won't work! If you use another version of vBulletin than I use enable "Ignore Language Version" to import the language pack.

Please note: (installing)
Installing this product will: (reverted during uninstall)
  1. rename a existing BB code "table" to "table_saved"
  2. add a new BB code [table]
If you want to have live sortable columns (JavaScript): Download attached sorttable.js.txt rename it to sorttable.js and place it into the /clientscript folder of your vBulletin. Then go to AdminCP -> vBulletin Options -> BB Code [table] Settings -> Enabled Features Of This BB Code and enable sortable
Note: Including the file on the webpages where it is necessary is done by my product. So if sortable is disabled, it won't be included automatically.
If you want to have a icon for the editor you may use this for free: Download this icon and place it in your /images/editor/ folder.

Please note: (usage)
  • Of course you can use vB Code and smilies inside the table!
  • The first line defines how much columns are in the table. If the other lines have more or less colums they are cut off or filled with   (space)
  • You can find a detailed description of the options (please read it before requesting help)
  • Empty rows are (should be ) removed.

New features
  • define colspan of cells
  • small panel in AdminCP
  • define CSS class of table and tablerows
  • live sorting of table through clicking the head of a column
  • defining maximum width of a table

Maybe planned features
  • detailed description of the vB Code in misc.php?do=bbcode depending on the features enabled in AdminCP (planned for next beta version)
  • define formatting (bold, italic), align (left, right, center) and width of the cols
Suggested but not planned features
  • none

Known problems
  • Bugfix of version 0.1.1 doesn't work if vBulletin should write template names into the source code

Angehängte Grafiken
Dosya tipi: jpg table_01.jpg (10,9 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: jpg table_02.jpg (10,1 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: jpg table_03.jpg (30,9 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: jpg table_04.jpg (96,9 KB (Kilobyte), 0x kez indirilmiştir)
Eklenmiş Dosya
Dosya tipi: xml table_bbcode-language-de.xml (5,5 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: xml table_bbcode-language-en.xml (5,1 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: txt sorttable.js.txt (6,8 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: xml product-bbcode_table-multi.0.1.6.xml (31,3 KB (Kilobyte), 0x kez indirilmiştir)
Dosya tipi: xml product-bbcode_table-multi.xml (33,4 KB (Kilobyte), 0x kez indirilmiştir)
  #2  
Alt 09 Ekim 2021, 15:10:00
vBulletin - ait Kullanıcı Resmi (Avatar)
Süper Moderatör
 
İstanbul Şubesi
Üyelik Tarihi: 03 Haziran 2004
Mesajlar: 724
Konular: 368
Aldığı Beğeni: 0
Verdiği Beğeni: 0
Standart Cevap: BB Code [table]

Introduction to options:
example: [table="option1;option2=value;option3='this is a long value with space';option4=value1,value2,value3"]
The whole option list should be wrapped with quotes.
Options are seperated by a semicolon
If an option has a value it is assigned with "equal to" mark. (option2)
If the value contains blanks or special characters it has to be wrapped with apostrophes. (option3)
If an option has more than one value they are seperated by a comma. (option4)

Description of options:
head
This option defines the first line as head, so the first row is shown as head of the table. If the table sould be sorted, the head is not sorted.

sort=1d,2,3
This defines the table to be sorted by column 1, then column 2, then column 3. The "d" after the first colum specifies the order: descending (default: ascending)

autonum=1 (equal to autonum) autonum=a autonum=A
Defines that a new first column containing a numbering should be inserted.
1 -> 1, 2, 3, 4, ... , 999, 1000, ....
a -> a, b, c, ... , aa, ab, ... , zz
A -> A, B, C, ... , AA, BB, ... , ZZ

autonumtitle=oneword autonumtitle='long value with spaces'
Defines the title of the autonum-column. Can be left empty.

width=123px width=45em width=67%
Defines the width of the table.

debug
My plugin outputs a simple comment line after the table.
"<!-- table generated by StG's vB Code [table] v.0.1.4 o.31 -->"
With this option the output gets more verbose:
"<!-- table has 3 rows, 2 cols with 36 chars. Parsetime: 0.47 ms at Wed 17th 2006, 12:24:42 pm by StG's vB Code [table] v.0.1.4 o.31 -->"
This is helpful for debugging especially if you want to know if this table comes from the cache or was generated.

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)

Introduction to special options (formating cells and rows):
example: {option1=value1}{option2=value2}
These "special" options can be written as the very first content of a cell to format it.

Description of special options:
{colsp=5}
Defines a colspan from current cell with the length of 5 cells

{css=myclass}
Defines the css class of the current row. This value is only valid in the first cell of a row and should be the first option (colspan defined after it - currently reversing the order works, too).

Cevapla Yeni Konu Aç

Tag Ekle
200, admincp, beta, code, description, editor, file, forum, free, hack, head, icon, javascript, left, live, manager, php, saved, shot, simply, size, style, table, url, vbulletin, work


Konuyu Toplam 1 Üye okuyor. (0 Kayıtlı üye ve 1 Misafir)
 
Seçenekler
Stil

Yetkileriniz
Sizin Yeni Konu Acma Yetkiniz var yok
You may not post replies
You may not post attachments
You may not edit your posts

BB code is Açık
Smileler Açık
[IMG] Kodları Açık
HTML-KodlarıKapalı
Trackbacks are Açık
Pingbacks are Açık
Refbacks are Açık


İçerik sağlayıcı paylaşım sitesi olarak hizmet veren macawforum.com adresimizde 5651 Sayılı Kanunun 8. Maddesine ve T.C.K nın 125. Maddesine göre tüm üyelerimiz yaptıkları paylaşımlardan kendileri sorumludur.

Şu Anki Saat: 16:53:34

 
Copyright © 2021
betexper
vdcasino
imajbet
casino metropol
eurocasino
mobil ödeme ile bahis
vdcasino giriş
vdcasino
bahis siteleri
Papara ile para yatırılan bahis siteleri