explain xkcd:Community portal/Design

Explain xkcd: It's 'cause you're dumb.
< explain xkcd:Community portal
Revision as of 09:14, 4 August 2012 by Waldir (talk | contribs) (Site logo)
Jump to: navigation, search


Community Portal
Dialog-information on.svg

Proposals (+post)
Place for ideas and suggestions to improve the wiki's design and organization on general issues.

Preferences-system.svg

Technical (+post)
Technical issues regarding the site, including bug reports or MediaWiki extensions requests.

Edit-find-replace.svg

Coordination (+post)
Community-managed page for coordinating content editing and maintenance tasks.

Tools-hammer.svg

Admin requests (+post)
Problems requiring assistance from an admin. User problems, changes to protected pages, etc.

Help-browser.svg

Miscellaneous (+post)
Place for general chit-chat about virtually anything that doesn't fit anywhere else.

View all community portal sections at once here
Hyperlink-internet-search.svg

Header template

Hi, I've created a template called Template:ComicHeader, which might make things easier when creating comic pages (and also provide better consistency between the pages). I've used it on the Internal monologue page, to display the comic number and the date it was published. The template also adds the page to the Comics category.

You just need to add:

{{ComicHeader|1089|August 1, 2012}}

…to the start of the page (replacing the comic number and date).

I'll try to make the template look a bit nicer, but the great thing about templates of course, is that once they're updated, the changes are reflected on all the pages that include that template. --Yirba (talk) 18:46, 1 August 2012 (EDT)

By the way, I'm thinking of maybe programming something that would allow you to easily import the comic image and alt text from xkcd without having to upload the images manually and the like. You'd just have to host a single PHP file on your server and make a few changes to the MediaWiki configuration. Of course, you'd be able to see source code and everything to make sure I'm not trying to do something fishy. :-P Let me know what you think. :-) --Yirba (talk) 18:54, 1 August 2012 (EDT)
Yirba - I like the idea. My email is [email protected] - send me what you put together and we can sort it out. --Jeff (talk) 19:37, 1 August 2012 (EDT)
Ditto on the Template. Up-vote. Any thought on harvesting the pre-wiki content from ExplainXKCD with some sort of a Python, Perl, or PHP script? (That sounds more like a 'bot than something that would have to be hosted, though.) IronyChef (talk) 01:52, 2 August 2012 (EDT)
I was thinking of putting it into a infobox, please see above. I also intended to automatically extract data from xkcd, which would lack descriptions, but at least we would have data like title, image and transcripts. Also, there are some other data like links (e.g. 832), news (which are displayed in xkcd's header, e.g. 739) and titles which contain HTML (259 and 472). I also extracted all those data. When we agree on a page layout, I could begin programming a bot. --SlashMe (talk) 06:54, 2 August 2012 (EDT)
Hmmm… an infobox may be a good idea. And a bot that imports data from xkcd might be handy. Anyway, here's something I programmed that would allow for access to the xkcd API from the wiki itself. Essentially, you'd put this xkcdinfo.php (source, download) file somewhere on the server (e.g. at http://www.explainxkcd.com/xkcdinfo.php) and include it in MediaWiki's interwiki table (ensuring iw_trans == 1):
INSERT INTO interwiki (iw_prefix, iw_url, iw_local, iw_trans) VALUES ('xkcdinfo', 'http://www.explainxkcd.com/xkcdinfo.php?input=$1', 0, 1);
After enabling scary transclusion in LocalSettings.php, you'd then be able to send queries to the xkcd JSON API via this file. In other words, {{xkcdinfo:32-title}} would make comic 32's title appear. {{xkcdinfo:55-alt}} would make comic 55's image text appear. I've also set it so you could enter {{xkcdinfo:100-embed}}, and it would make the comic 100 image appear on the wiki page. Feel free to use it however you want (if at all), and modify the code should you wish. (Hint: Using the number 0 for the comic number will query the most recent comic, so {{xkcdinfo:0-num}} will return the current comic number. Also, adding "raw:" before "xkcdinfo:" might be more useful in some instances. E.g.: {{raw:xkcdinfo:555-title}})--Yirba (talk) 14:50, 2 August 2012 (EDT)
Nice idea, altough this would mean to load all data from xkcd whenever a page is viewededited (I think this is the way MediaWiki caches the data). This is a lot of traffic for little data. I'd say to include the metadata statically, but linking the external image seems a good thing to me. Again, it'd be great if you gave me feedback for my idea. --SlashMe (talk) 15:54, 2 August 2012 (EDT)
Yes, the data would be loaded from xkcd for each edit. You can, however, substitute (subst) the template for data that is unlikely to change. And therefore the data would indeed be stored statically. I like the layout you've come up with. It could perhaps do with a bit of tweaking here and there, but the general idea is good. --Yirba (talk) 17:16, 2 August 2012 (EDT)
What kind of tweaking do you mean? I know the code is a bit messy, if you have a better idea, please tell me (or do it yourself - hey, it's a wiki!). The CSS should be placed in an external file, but for now, it's ok. --SlashMe (talk) 17:51, 2 August 2012 (EDT)

Looks like there is another/newer template called Template:Comic that includes prev/next buttons as well. You add it with:

{{comic
| number    = 1
| date      = September 30, 2005
| title     = {{PAGENAME}}
| image     = barrel_cropped_(1).jpg
| imagesize = 
| alttext   = Don't we all.
}}

<small>Moved from [[User talk:Jeff]]. --~~~~</small>
==Description==
xxxxxxxxxxx

No need to include the alt text separately, as the template does it for you. It also includes the comic category, but only if the first 4 fields are filled out. --B. P. (talk) 18:47, 3 August 2012 (EDT)

Yes, but that is not necessarily an advantage. My template only creates the infobox, so you are still able to create an introductory text or other sections, for special comics that need a more detailed description. I can also add categories if needed. --SlashMe (talk) 19:02, 3 August 2012 (EDT)
I think it is a major advantage to make the thing easier to use and more consistant site-wide.
As the creator of the new one, I'm obviously biased, but I created it because I think it's better. Not putting your work down, it was a great piece of code that I put to work in my template. But I think if there's need for pre-text of any kind (not sure there is, as the articles probably should all open with the comic itself as presented on XKCD), a pre-comment can be added into the template, but I'm not sure what that would be. Perhaps there would be a requirement for special circumstances like the comic a few weeks ago where there were a million iterations depending on locality, browser, etc. But that's the rarity. I think the new one simplifies it for users. They need only one template to post the comic, alt text title and nav buttons. What could be easier? TheHYPO (talk) 19:08, 3 August 2012 (EDT)
As the creator of the other one, I'm equally biased. What about a "main template", which then calls one or two other templates (e.g. one for the infobox, another for image and alt text? For most comics, this main template could be used, but if absolutely needed, it would still be possible to use the underlying templates with custom sections/text. --SlashMe (talk) 19:15, 3 August 2012 (EDT)
I just now saw your request for feedback on your new comic page with the sidebar. I honestly am not sure which format is better. I kind of like my format for the fact that it basically presents the comic as it was originally posted, but your infobox does provide some additional stuff like 3D link (not sure what "news" is, of where the "link" comes from but...) Perhaps we could integrate the two. I like that the comic is visble right away on my template, but on your page it's down below the first header. I don't think the comic itself needs an "image" heading. No disrespect, but I think your sidebar, esp. because of the "news" field is a bit chunky - too wide for most of its content.
I think we could easily add things like a "3d" link into {{comic}} as part of the next/prev bar where a "3D" field in the template is non-blank. Similarly, original title could read something like (Originally titled: xxxxx) below the primary title in a smaller font. Other than the "link" and "news" fields (which again, I'm not sure what they are), I think that would inclde all the same info as your infobox into my template. Thoughts?
As to your other comment about compartmentalizing the template, I have nothing against that, but which parts of the template would you want to be able to use separately (and can you suggest an example where that might be necessary?) Subdividing the template can always be done later if it becomes needed; just trying to get an idea of what you have in mind by compartmentalizing it. Cheers TheHYPO (talk) 19:43, 3 August 2012 (EDT)

Moved from User talk:Jeff. --Philosopher Let us reason together. 00:37, 4 August 2012 (EDT)

────────────────────────────────────────────────────────────────────────────────────────────────────

Suggestion:

  • I will start by uploading all images. This will take some time and has no points to discuss. (If it has, tell me.) At a later point, maybe we could link them directly from xkcd.com.
  • For the comic pages: Let's say we'll use {{Comic}}. I'll change the arguments of the template to be more like my {{Infobox comic}}, see documentation. I'll keep the alttext argument, but make image optional (file name should be guessed from the title). Do we really need imagesize?
  • {{Comic}} would then call some further templates, passing the appropriate arguments. This way, we are able to use custom sections/text if needed for special comics (like Umwelt) by using these templates instead of the all-in-one {{Comic}}.
  • Since we have one template doing all the work, we can easily change the page layout even after the import. (We should only keep track of the pages that don't use {{Comic}}, using a hidden category)
  • For consistency, I would move all existing pages out of the way and re-create them. The moved pages could be collected by adding them to a category like Category:legacy pages, so they should easily be found. Descriptions should be moved to the new pages, afterwards the legacy pages can be deleted.

This way, I can import all comics, but we would still be able to change the layout afterwards. My 2ct concerning page layout:

  • Use comic titles as page names. The title should be prominent, the number will be in the infobox.
  • I'll remove Original title, news and link from the infobox and move them to a section after the description. (For details, see here)
  • suggested layout:
=====page title=====
+--------------------+ +---------+
|                    | | infobox |
|       image        | |  text   |
|(no section heading)| |         |
|                    | |         |
|                    | +---------+
+--------------------+
==alt==
text
==description==
text
==transcript==
text
==original title, news and link== (if available)
text

Still open for opinions.--SlashMe (talk) 04:13, 4 August 2012 (EDT)

The main image (top left) is not the best image ever. You really need to update it.

Maybe: Wiki.png

Just an idea, because that text looks weird, or at least please add a transparent background instead of white for the logo (and center the text). --Grep (talk) 21:39, 1 August 2012 (EDT)

I like it. What does everyone else think? (PS - don't forget to sign your entries on this page!) --Jeff (talk) 21:18, 1 August 2012 (EDT)
I could go with that. Had been kicking around some ideas, and if I had any artistic aptitude, it might have looked very much like that: the black-hat retort; alternately: the lowercase blue xkcd that RM uses (sans comic figure watermark) with a "Explain" in a hand-written typeface in some other color splashed across the top left part of those letters. And yes, definitely with transparency. Just thoughts... ultimately, whatever the consensus is... IronyChef (talk) 01:51, 2 August 2012 (EDT)
Something like one of the following?
Wiki2.pngWiki3.pngwiki4.png
--Grep (talk) 12:40, 2 August 2012 (EDT)
I like that first one - File:wiki.png. And perhaps use that same text for the Tagline? --Philosopher Let us reason together. 19:50, 2 August 2012 (EDT)
Yeah, the first one captures what I was thinking. I thought I'd download it to tweak it a bit, and quickly proved to myself how unartistic I am. I was thinking the xkcd pretty much overwhelming the bottom (touching all three sides) and the explain (first typeface) in tight, maybe at a 5 degree angle over the x and k. Of course envisioning it is one thing, realizing it another (it may be totally unrealistic...) but I toss that out for further consideration. -- IronyChef (talk) 00:25, 3 August 2012 (EDT)
Hmmm, rereading Philosopher's comment, I think he and I may have been talking about two different images. Ooops. Anyway, was just chatting with a buddy who is more artistic than I am, and he created this mashup. He suggested: "Establish some vocabulary. First, xkcd needs to be bigger; it defies describing, and refuses to be pidgeon-holed into a box, so the xkcd needs to be so big that it doesn't fit entirely in-frame ... the Explain part has got to be casual, to represent the wiki and informal nature of contributing to it, and you gotta have it in close, because the contributors are going to get as close as they can to the truth. And keep it simple." (I broke with that, and tried to add the black hat; in doing so, I think I trashed transparency, tough) Anybody think that's worth taking a run with it? -- IronyChef (talk) 01:04, 3 August 2012 (EDT)

Explainxkcd-concept.PNG

   y
   o
   u
   '
 w r
ei e
xkcd
piau
l um
a sb
i e
n

Moved from User talk:Jeff. --Philosopher Let us reason together. 00:37, 4 August 2012 (EDT)

I prefer the first option (file:wiki.png). At the size the logo is meant to be, it's perfectly readable; furthermore, it's visually pleasant and it conveys the meaning well. --Waldir (talk) 05:14, 4 August 2012 (EDT)

Displaying Comics

For the home page, I think the comic and explanation should be displayed instead of a link to the comic.

For reasons unknown to me, I decided to create Template:Comicbox and Template:Comicbox2. Looks nice, as long as you use the correct one for the comic.

Go to User:Grep/comicbox and User:Grep/comicbox2 for examples. --Grep (talk) 21:03, 2 August 2012 (EDT)

Those're wonderful! And should probably be on the main page. If you wanted, we could probably incorporate them (and maybe a third?) into a single template with a "square/vertical or horizontal" switch. --Philosopher Let us reason together. 21:36, 2 August 2012 (EDT)
Also, you used "comicbox" for the class. Is that a class that's defined somewhere? (And if so, where?) --Philosopher Let us reason together. 21:36, 2 August 2012 (EDT)
Good point. Removed. And merging them sounds wonderful. --Grep (talk) 21:47, 2 August 2012 (EDT)
Maybe merging them into Template:comicbox? --Grep (talk) 21:49, 2 August 2012 (EDT)
I think classes are defined at MediaWiki:Common.css, so if you really wanted to define the class.... And Template:Comicbox would probably be best. Did you want to merge them or should I take a look at it? --Philosopher Let us reason together. 22:25, 2 August 2012 (EDT)
ParserFunctions and any sort of non-XMLish markup is weird. I would rather you look at it. --Grep (talk) 22:42, 2 August 2012 (EDT)
Okay, I've moved your templates to {{Comicbox square or vertical}} and {{Comicbox horizontal}} so I can work on {{Comicbox}} as the main one. It may take a while - I like to think of myself as a "master of all known wikimarkup," but I don't actually use those skills that often. --Philosopher Let us reason together. 23:08, 2 August 2012 (EDT)
Thanks. --Grep (talk) 23:42, 2 August 2012 (EDT)
I've made it at {{Comicbox}}. This actually leaves {{Comicbox square or vertical}} and {{Comicbox horizontal}} unused, though I credited you (and them) in a comment at the top of the template. --Philosopher Let us reason together. 00:21, 3 August 2012 (EDT)
I think that the explanation should be on the right because it just looks weird as is... --Grep (talk) 07:42, 3 August 2012 (EDT)

──────────────────────────────────────────────────────────────────────────────────────────────────── Sure. But right now they both look like they're on the bottom? --Philosopher Let us reason together. 20:02, 3 August 2012 (EDT)

Sans-serif typeface

I like these, too, but the roman typeface... how do folks feel about sticking with a sans-serif typeface throughout the site? IronyChef (talk) 00:13, 3 August 2012 (EDT)
We should be able to change that wiki-wide through MediaWiki:Common.css, I think. Unfortunately, I don't know enough CSS to do it. --Philosopher Let us reason together. 00:23, 3 August 2012 (EDT)
I believe sans serif is already the default wiki-wide. Those specific instances were deliberately coded to use a serif font. It's just a matter of removing font-family: 'Times New Roman'; from the template. --Waldir (talk) 17:01, 3 August 2012 (EDT)
Oh, I'd missed that. I removed it. --Philosopher Let us reason together. 22:14, 3 August 2012 (EDT)

Moved from User talk:Jeff. --Philosopher Let us reason together. 00:37, 4 August 2012 (EDT)

comic header

Jeff, further to your previous conversation on the comic header, I've significantly rewritten Yirba's template (thanks to Yirba for the hard work. His navigation bar was very useful) and I've created a new template of {{comic}}. An example of the comic in use can be seen at T-shirts. I started a discussion on the main page discussion board, but I thought if I pointed it out to you and you like it, it can start going in the rotation for new comics.

I actually now see that Grep did a template up with intent (I think) to use for the main page. Had I known that when I started, I would have probably based my template off of his, because it looks nice, but either way, mine is intended for the actual articles. TheHYPO (talk) 14:46, 3 August 2012 (EDT)

Again, may I link to my request for feedback? --SlashMe (talk) 15:52, 3 August 2012 (EDT)

The discussion is now at Explain XKCD:Community_portal/Design#Header template. --SlashMe (talk) 04:17, 4 August 2012 (EDT)

Moved from User talk:Jeff. --Philosopher Let us reason together. 00:37, 4 August 2012 (EDT)

Template improvement suggestion

Can I suggest that we work on improving {{ComicHeader}} - I wish I had time to do it myself and then edit all the comic pages, but I would suggest the best way might be to start a new template (perhaps design it a bit more like an infobox) and start converting the old pages over to new ones.

The feature I think should be added is that, where the template currently includes teh comic number and date, and creates the nav header, the template really ought to include the image name, and the alt text. In that way, the template can produce the entire part of the article that displays the comic and its alt text (and the alt text, as mentioned, could be more like a caption, instead of just looking like a generic section of the article - it's part of the comic, it shouldn't look like part of the article on this site (no offence, Jeff, but that's one thing I always didn't like about explain XKCD - the image text should be bold or underlined or italics or something to signify that it's part of the comic and not the explanation.

I'll see if I can work on a prototype. TheHYPO (talk) 12:29, 3 August 2012 (EDT)

What does everyone thing of this as a better layout? Blown Apart TheHYPO (talk) 13:09, 3 August 2012 (EDT)
May I link to my request for feedback? --SlashMe (talk) 15:52, 3 August 2012 (EDT)

Moved from Talk:Main Page. --Philosopher Let us reason together. 00:44, 4 August 2012 (EDT)

The discussion is now at Explain XKCD:Community_portal/Design#Header template. --SlashMe (talk) 04:17, 4 August 2012 (EDT)

Transcripts

Do we need to add a whole section on "Transcript" for each comic? That could get very long for some comics, and basically pushes the explanations down further (which is what people generally come to explainxkcd for). If anything, perhaps the transcripts could be in a minimizable box like some navboxes do on wikipedia? I don't see a majority of users coming to read the transcripts... TheHYPO (talk) 19:15, 3 August 2012 (EDT)

What about putting the transcripts at the bottom of the page?
BTW: If you agree, this discussion should be moved to Explain XKCD:Community portal, as Waldir suggested. At least for new discussions. --SlashMe (talk) 19:19, 3 August 2012 (EDT)
No problem there. Feel free to move it. TheHYPO (talk) 19:29, 3 August 2012 (EDT)

Moved from Talk:Main Page. --Philosopher Let us reason together. 00:47, 4 August 2012 (EDT)

The discussion is now at Explain XKCD:Community_portal/Design#Header template. --SlashMe (talk) 04:18, 4 August 2012 (EDT)

Adding a new comic

This is the process I use to add a new comic. YMMV... Feel free to update this as/if needed to provide some consistency...--B. P. (talk) 19:22, 3 August 2012 (EDT)

I start by uploading the image using the name from XKCD's page.

I create the new page using the comic number(not the name), e.g. "http://www.explainxkcd.com/wiki/index.php?title=1"

I (currently) insert using the "Comic" template:

{{comic
| number    = 1
| date      = September 30, 2005
| title     = {{PAGENAME}}
| image     = barrel_cropped_(1).jpg
| imagesize = 
| alttext   = Don't we all.
}}
==Transcript==
This is the transcript from xkcd
==Description==
Wow what a cool comic!

I "Show preview" to ensure the image shows up and everything looks good.

I "Save page".

I click the "move" link on the down-arrow drop-down menu to the right of "View history" (at top of page).

I rename the page from "1" to the page title from XKCD.

This will automatically create a redirect from "1" to the correct page name without having to do it manually. --B. P. (talk) 19:22, 3 August 2012 (EDT)

Please, have a break here. When we agree on a page layout, I can do this automatically. I repeat, when we agree on the layout (which should also include the direction of the redirects) --SlashMe (talk) 19:25, 3 August 2012 (EDT)

Moved from Talk:Main Page. --Philosopher Let us reason together. 00:47, 4 August 2012 (EDT)

The discussion concerning the layout is at Explain XKCD:Community_portal/Design#Header template. --SlashMe (talk) 04:18, 4 August 2012 (EDT)

styling of xkcd links

I added code to the end of MediaWiki:Common.css to style links to the xkcd website as http://xkcd.com rather than the regular external link format, http://example.com. What do you guys think? --Waldir (talk) 05:06, 4 August 2012 (EDT)