Mount & Blade Wiki
Forums: Index > Wiki Talk > Normalize style



The tables in the hero pages have different styles (i just copy paste from existing pages). We should either define classes for the tables in the wiki's css (MediaWiki:Common.css / MediaWiki:Wikia.css) or create templates that generate the tables (Template:Hero Stats / Template:Hero Skills / Template: Hero Proficiencies).

Flaviojs 02:59, January 2, 2012 (UTC)

Yeah, I know. I was going to fix that a long time ago, but I just keep procrastinating. It'll get done eventually. ◄► Tephra ◄► 20:21, January 2, 2012 (UTC)


Ok, for css I suggest adding this to MediaWiki:Common.css:

/* Generic gray table style */
.graytable table {
   margin: 1em 1em 1em 0pt;
   background: #f9f9f9;
   font-size: 95%;
   border: 1px #AAA solid;
   border-collapse: collapse;
   border-spacing: 0px;
   padding: 4px;
}

.graytable th {
   text-align: center;
   background-color: #CCC;
}

(It's a special page so I can't edit it)

Flaviojs 07:34, January 3, 2012 (UTC)

Well that's... interesting. I am fairly experienced with template coding, but I have never messed with css like that. However, I am not afraid of learning new things and that doesn't look too far removed from templates. So how would you use that table in an article? I'm treading on unfamiliar ground here, but I'm personally leaning toward templates, not because I at least know what I am doing, but I think I can make them much more simple to use; e.g. not filling out skill rows will result in a "0" by default, allowing you to ignore all skills they don't have any points in. ◄► Tephra ◄► 13:30, January 3, 2012 (UTC)


It's just a named style so it can be used in the templates too. You use it by putting class="graytable" in the {| line instead of all the other stuff.

Example:

{| class="graytable"
! Header
|-
| Cell
|}

Flaviojs 14:47, January 3, 2012 (UTC)

Oh ok, that makes sense. So I can make that, and the templates as well then. Is there a specific location in the css I should put it? ◄► Tephra ◄► 16:18, January 3, 2012 (UTC)


There isn't a specific location, just add it to the end of MediaWiki:Common.css. ;D

Flaviojs 20:28, January 3, 2012 (UTC)

Done. Now to make the templates. ◄► Tephra ◄► 22:09, January 3, 2012 (UTC)


Tried using it but it didn't work. Inspecting the page elements told me the style didn't exist... >.< Searched for the problem and found this topic. We need to add this to MediaWiki:Wikia.css:

/* LEAVE THIS IMPORT ABOVE EVERYTHING ELSE */
/* see: http://community.wikia.com/wiki/Forum:Common.css */
@import url("http://mountandblade.wikia.com/index.php?title=MediaWiki:Common.css&usemsgcache=yes&ctype=text/css&smaxage=86400&action=raw&maxage=86400");

Flaviojs 00:01, January 5, 2012 (UTC)

I've given you Admin rights so you can tinker around with this stuff. For now, consider it temporary, but I may just let you keep the promotion. ◄► Tephra ◄► 03:22, January 5, 2012 (UTC)
what why?, well that sucks, 2 min and he's adminNever tell your problems to anyone...20% don't care and the other 80% are glad you have them. 09:23, January 5, 2012 (UTC)


Took a couple of tries but finally got the graytable css style working. =) (see test table in my profile)

I'm much more familiar with templates than css so I can do them too. Which strategy should be used?

  • Template:Hero - generates whole page (what I used in the GhostX Wiki)
  • Template:Skills/Template:Proficiencies/... - used for heroes and troops, generates the table and autofills with 0 by default
    • also generate the header?
    • how should the template for stats/attributes handle the initial level?
  • other...

Flaviojs 11:17, January 5, 2012 (UTC)

Individual templates for the three stats would be best I think, easier to see what you are doing. The default data for things other than skills should be a "?" I think. And Mikeymikeymikey, administrators are supposed to be useful to the wiki, not a rank to flaunt your popularity. Flaviojs had the ability to make this wiki better, if Flaviojs starts screwing around and abusing the power, I will retract the promotion so fast, it will cause a small meteorological disturbance in the lower atmosphere. ◄► Tephra ◄► 12:57, January 5, 2012 (UTC)

i tried to be useful ish, but kinda failing to do so, i try to add it, what i can.