Help talk:Tables

Let's keep it simple at the top and add tricks in extra sections down the page. Cheers :-) --Rogerhc 07:07, 4 September 2006 (UTC)

Page layout
The page is laid out as follows:
 * Under each heading is a 2 column parent table with the example table nested into its left column and the example's wiki markup in pre tags in the right column.
 * The parent table is width="100%" and the two columns containing the nested tables are each width="50%". Pre tags containing long lines in the right column override its width="50%" attribute in most browsers which is good flexible browser behavior.
 * None of the page's sectional headings, H1, H2, H3, etc. are within tables, except the one in the example of how to do that. This avoids the to some confusing problem that when one previews an edit section within a parent table the parent table previews as broken; broken because the part of it above the edit section previewed is outside of and thus not parsed in the section previewed.

This will work well in most browsers I think.

Let us know if the layout brakes anything in your browser and which browser and version that is.

--Rogerhc 17:44, 4 September 2006 (UTC)

Headings in tables
Of course, you can use headings within tables. Your above note on "MediaWiki not supporting this" is wrong. -- :Bdk: 11:11, 4 September 2006 (UTC)
 * Thank you. I have now added a section on Tables with H1, H2, H3 etc. headings. :-) Rogerhc 04:45, 5 September 2006 (UTC)

Tables in Excel (/Calc) converted to Wiki Markup
Is there any software available to convert an "Microsoft Excel" or "Open-Office Calc" table into a MediaWiki markup text document?

Would this be something people would consider usefull, as if it doesn't already exist, and there is a demand, I could a quick, basic one, as I use quite a few tables in my wiki.--Barryred


 * Yes! This would be absolutely helpful! --Nino Gonzales 04:10, 26 January 2007 (UTC)


 * See m:User talk:DBP.--Patrick 08:57, 26 January 2007 (UTC)

I've not tried this as I'm not a Python man but it might help. http://just-tech.blogspot.com/2007/01/python-html-tables-to-mediawiki.html --Dopple 09:27, 18 October 2007 (UTC)

Cellpadding doesn't work
Old discussion deleted since this issue was fixed

...but thanks to Splarka for figuring out where the problem was in the CSS and Bdk for fixing it. -- Harry Wood 12:10, 4 January 2008 (UTC)

CSS style background-image not working inside cell style
Inside a cell the style parameter seems not to accept the parenthesis in. See sample code:

Here is the table:

I tried using a template (like the  | ) and tried using &amp;#40; and &amp;#41;. Do I see/do something wrong? How could I solve this? Didn't find anything in the docs or discussions yet...

- 80.254.136.33 - 11:19, 14 February 2008


 * Yeah most CSS within the style attribute should work ok, but I think any mention of 'url' is forbidden. So you can't use background images.
 * I could be wrong about that, but style attribute checking happens in includes/Sanitizer.php in the checkCSS function, and the comments there mention that urls are forbidden.
 * Probably the reason is to prevent certain kinds of minor security issues, people trying malicious CSS tricks. There is a setting Manual:$wgAllowExternalImages which malicious users might try to devise a workaround for, using style urls like this.
 * -- Harry Wood 14:28, 14 February 2008 (UTC)