Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

3562 Posts in 677 Topics- by 443 Members - Latest Member: ludus529
Pages: [1] 2
Print
Author Topic: Infoboxes?  (Read 681 times)
0 Members and 1 Guest are viewing this topic.
chrisco97
Jr. Member
**
Posts: 48


View Profile
« on: June 14, 2012, 15:25:04 »

Can someone please explain to me infoboxes? I have spent forever trying to figure out how to use them. I read about Wikipedia's script, however I do not understand how to make one suitable for my wiki. Any help is appreciated on this subject! biggrin
Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #1 on: June 14, 2012, 15:44:20 »

Can someone please explain to me infoboxes? I have spent forever trying to figure out how to use them. I read about Wikipedia's script, however I do not understand how to make one suitable for my wiki. Any help is appreciated on this subject! biggrin
Basically an infobox is a template that draws a table, usually on the right side of the page.  If you have a large number of similar pages (ships, characters, cities, racing cars) you use a template to give uniformity to your pages.

Wikipedia often uses quite complex infobox templates, because they keep them very generic.  You can certainly start with a much simpler one.
Logged
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #2 on: June 14, 2012, 17:53:23 »

I know what they do, I am just unsure on how to make one. I am lost on the whole subject. Wink
Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #3 on: June 15, 2012, 01:21:52 »

I know what they do, I am just unsure on how to make one. I am lost on the whole subject. Wink
Have you written a template?  If not, you may want to review http://www.mediawiki.org/wiki/Help:Templates.

If you have some idea, but would like a sample simpler than most in wikipedia, you can look at one I made here: http://aspartanswar.wikinet.org/wiki/Template:Characters
Logged
Sasha Ehrenstein
Hero Member
*****
Posts: 504


Community Wiki Staff


View Profile WWW
« Reply #4 on: June 15, 2012, 08:04:53 »

I have an infobox here that I'm working on.

http://en.sturmkrieg.com/Sandbox
http://en.sturmkrieg.com/Template:Characterinfo

If you could join and help out, that would be great.

It seems that {{!}} is just a pipe character.  Do I need to use it instead of |?  For some reason, the infobox isn't working.
Logged

Community Wiki Founder
http://community.wikkii.net

Sturmkrieg unoffical Warhammer gaming and fanfiction encyclopedia.
http://www.sturmkrieg.com

http://www.sturmkrieg.de
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #5 on: June 15, 2012, 09:04:03 »

Thanks for the responses! I am sure this will help me in the process of getting infoboxes up and running. I will let you know how it goes. Wink
Logged
Sasha Ehrenstein
Hero Member
*****
Posts: 504


Community Wiki Staff


View Profile WWW
« Reply #6 on: June 15, 2012, 12:44:41 »

Alright, thanks for linking your infobox.  I'm currently working on the one that I linked above; you can see a preview of it in the sandbox, which I have also linked.

Is there a way that I can put the general statistic in a column on one side, and the user input characteristic on the other?
Logged

Community Wiki Founder
http://community.wikkii.net

Sturmkrieg unoffical Warhammer gaming and fanfiction encyclopedia.
http://www.sturmkrieg.com

http://www.sturmkrieg.de
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #7 on: June 15, 2012, 12:54:03 »

Alright, thanks for linking your infobox.  I'm currently working on the one that I linked above; you can see a preview of it in the sandbox, which I have also linked.

Is there a way that I can put the general statistic in a column on one side, and the user input characteristic on the other?
Sure, just use the tables, like I did in my templates.  You can use either the mediawiki table syntax, or HTML-style table syntax.
Logged
Sasha Ehrenstein
Hero Member
*****
Posts: 504


Community Wiki Staff


View Profile WWW
« Reply #8 on: June 15, 2012, 13:59:18 »

Thanks.

Is there a way that I can center the character name and image within the infobox?
Logged

Community Wiki Founder
http://community.wikkii.net

Sturmkrieg unoffical Warhammer gaming and fanfiction encyclopedia.
http://www.sturmkrieg.com

http://www.sturmkrieg.de
Sasha Ehrenstein
Hero Member
*****
Posts: 504


Community Wiki Staff


View Profile WWW
« Reply #9 on: June 15, 2012, 14:14:53 »

I seem to have just got it.
Logged

Community Wiki Founder
http://community.wikkii.net

Sturmkrieg unoffical Warhammer gaming and fanfiction encyclopedia.
http://www.sturmkrieg.com

http://www.sturmkrieg.de
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #10 on: June 15, 2012, 15:24:02 »

I created a page (Template: Character Infobox) and placed this in it:

Code:
| above =
| image =
| born =
| died =
| birthplace =
| role =
| best_known_as =
| occupation =
| gender =

And placed this in my page:

Code:
{{Character Infobox
 | above = Sherlock Holmes
 | image = Sherlock Holmes.jpeg
 | born = January 6th, 1854
 | died = Unknown
 | birthplace = Unknown
 | role = Main Character
 | best_known_as = The greatest detective of all time
 | occupation = Consulting Detective
 | gender = Male
}}

And I get this on my page:

| above = | image = | born = | died = | birthplace = | role = | best_known_as = | occupation = | gender =
« Last Edit: June 15, 2012, 15:28:43 by chrisco97 » Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #11 on: June 15, 2012, 15:29:29 »

I created a page (Template: Character Infobox) and placed this in it:

Code:
| above =
| image =
| born =
| died =
| birthplace =
| role =
| best_known_as =
| occupation =
| gender =

And placed this in my page:

Code:
{{Character Infobox
 | above = Sherlock Holmes
 | image = Sherlock Holmes.jpeg
 | born = January 6th, 1854
 | died = Unknown
 | birthplace = Unknown
 | role = Main Character
 | best_known_as = The greatest detective of all time
 | occupation = Consulting Detective
 | gender = Male
}}

But nothing happened. :|

You need to add the actual table-drawing code in your Template page.

Something like
Code:
{| class="infobox"
 |-
 ! colspan="2" style="text-align:center;" | {{{name|{{PAGENAME}}}}}
 |-
etc. etc.
 |}
Logged
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #12 on: June 15, 2012, 15:34:11 »

How would I add this to my template? Sorry if I seem stupid, I have little to no experience with MediaWiki.
Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #13 on: June 15, 2012, 15:36:05 »

How would I add this to my template? Sorry if I seem stupid, I have little to no experience with MediaWiki.
Have you looked at the code for http://aspartanswar.wikinet.org/wiki/Template:Characters?
Logged
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #14 on: June 15, 2012, 15:37:45 »

Yeah, but I do not see the table-drawing code...
Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #15 on: June 15, 2012, 15:39:06 »

Yeah, but I do not see the table-drawing code...
The snippet I posted comes from there.  It starts with "{| class=..."
Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #16 on: June 15, 2012, 15:40:02 »

The snippet I posted comes from there.  It starts with "{| class=..."
You did look at "View Source" or "Edit", right?
Logged
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #17 on: June 15, 2012, 15:41:46 »

I see it now...how would I add this to my infobox? smile
Logged
samuelmichaels
Full Member
***
Posts: 114


View Profile
« Reply #18 on: June 15, 2012, 15:42:33 »

I see it now...how would I add this to my infobox? smile
Um, edit, and start typing?
Logged
chrisco97
Jr. Member
**
Posts: 48


View Profile
« Reply #19 on: June 15, 2012, 15:47:50 »

Yeah, I know...but I do not how to properly add this so it supports my template.
Logged
Pages: [1] 2
Print
Wikkii Suport ForumSupport CategoryTechnical SupportTopic: Infoboxes?
Jump to: