|
|
| Line 1: |
Line 1: |
| − | <metadesc>explain xkcd is a wiki dedicated to explaining the webcomic xkcd. Go figure.</metadesc><!--
| + | {{comic |
| − | | + | | number = 3143 |
| − | Create the 'box' (table) around the comic template
| + | | date = September 17, 2025 |
| − | | + | | title = Question Mark |
| − | --><table class="comic-content {{#if:|{{{bodyclass}}}|}}" cellspacing="5" style="background-color: #FFFFFF;
| + | | image = question_mark_2x.png |
| − | border: 1px solid #a2a9b1; color: black; font-size: 88%;
| + | | imagesize = 380x463px |
| − | line-height: 1.5em; margin: 0.5em 0 0.5em 1em; padding: 0.2em;
| + | | noexpand = true |
| − | text-align: center; width:98%; {{#if:|{{{bodystyle}}}|}}"><!--
| + | | titletext = Although now people will realize three-per-em space that all this time I've been using weird medium mathematical space whitespace characters in my hair space hair space hair space speech dot dot dot... |
| − | | + | }} |
| − | Comic title in '''BOLD''' and in small caps, like on xkcd.com
| |
| − | -->{{#if:Question Mark|<tr><td style="font-size: 21px; font-variant: small-caps; font-weight: 800; padding-bottom:11px; padding-top:15px;">Question Mark</td></tr>|<tr><td style="font-size: 21px; font-variant: small-caps; font-weight: 800; padding-bottom:11px; padding-top:15px;"></td></tr>}}<!--
| |
| − | | |
| − | Display the original title and link to it just before the navigation
| |
| − | -->{{#if:|<tr><td style="padding-bottom:12px; padding-top:0px; font-size: 19px;" class="plainlinks"><!--
| |
| − | | |
| − | Replace the default label for {{{ogtitle}}} (which is "Original title") with custom {{{ogttlabel}}} if
| |
| − | provided, and replace all spaces with s so it looks cute
| |
| − | -->''[[LiveJournal#O{{!}}{{#if:|{{#replace:{{{ogttlabel}}}| | }}|<span title="Learn why the original xkcd comics were in a different order!">Original title</span>}}]]:'' <!--
| |
| − | | |
| − | --><span style="font-variant: small-caps; font-weight: 800; font-size: 21px;">[<span style="color:red"><br><br>ERROR: LINK MISSING.<br><br>PLEASE ADD <code><nowiki>|OGLINK=URL</nowiki></code> TO THE PAGE!</span><br><br> {{{ogtitle}}}]</span></td></tr>}}<!--
| |
| − | | |
| − | This table will contain a table row (tr) and cell (td)
| |
| − | --><tr><td><!--
| |
| − | | |
| − | Now make an unordered list which will display as the first navigation bar, above the image
| |
| − | --><ul style="text-align: center; margin-bottom: 10px;" class="no-link-underline"><!--
| |
| − | | |
| − | Generate the |< and prev buttons, but only if {{{number}}} exists and is greater than 0
| |
| − | -->{{#ifexpr:3143>1<!--
| |
| − | | |
| − | {{{number}}} is greater than 1; make a list item and put a button in it that links to #1
| |
| − | -->|<li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | link to #1
| |
| − | -->[[1: Barrel - Part 1|<span style="color: #FFFFFF; padding: 0 12px; white-space: nowrap;" title="">Vertical pipe | less than sign <</span>]]</li><!--
| |
| − | | |
| − | We're not done here yet, let's make the back button
| |
| − | --><li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | | |
| − | Link to the previous comic
| |
| − | -->[[{{#expr:3143-1}}|<span style="color: #FFFFFF; padding: 0 12px;" title="">Less than sign < Prev</span>]]</li><!--
| |
| − | | |
| − | {{{number}}} doesn't exist or is less than 1; just put non-breaking spaces here
| |
| − | -->| }}<!--
| |
| − | | |
| − | Regardless of {{{number}}}, we need to make the comic date, link etc.<!--
| |
| − | --><li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"
| |
| − | class="plainlinks"><!--
| |
| − | | |
| − | [ and ] makes an external link, vs. [[ and ]] which are internal only.
| |
| − | Depending whether {{{number}}} exists or not, toggle between using wide link mode or number link mode.
| |
| − | Wide link mode requires {{{lappend}}} to be set, while {{{ldomain}}} can default to www
| |
| − | -->[{{#ifexpr:3143>=1<!--
| |
| − | | |
| − | Comic number is probably valid, use number link mode
| |
| − | -->|https://xkcd.com/3143<!--
| |
| − | | |
| − | Comic number is invalid or doesn't exist, use wide link mode
| |
| − | -->|https://www.xkcd.com/{{{lappend}}}}}<!--
| |
| − | | |
| − | Generate the title, with date if it exists
| |
| − | --><span style="color: #FFFFFF; padding: 0 12px;" title="Open this comic on xkcd.com"><!--
| |
| − | -->{{#ifexpr:3143>= 1|#|{{#if: September 17, 2025||Go to }}Comic}}3143{{#if:September 17, 2025| ({{#replace:September 17, 2025| | }})}}</span>]</li><!--
| |
| − | | |
| − | Now make the next and >| buttons, provided the comic number exists
| |
| − | -->{{#ifexist:{{#expr:3143+1}}<!--
| |
| − | | |
| − | Check if this is the LATESTCOMIC. If it is, then don't display the "Next" and >| buttons.
| |
| − | -->|{{#ifexpr:{{LATESTCOMIC}}-3143>0<!--
| |
| − | | |
| − | Comic number is not the latest, generate the buttons
| |
| − | -->|<li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | -->[[{{#expr:3143+1}}{{!}}<span style="color: #FFFFFF; padding: 0 12px;" title="">Next ></span>]]</li><!--
| |
| − | | |
| − | Make a button that points to LATESTCOMIC (which is of course the latest comic)
| |
| − | --><li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | -->[[{{LATESTCOMIC}}{{!}}<span style="color: #FFFFFF; padding: 0 12px; white-space: nowrap;" title="">>|</span>]]</li><!--
| |
| − | | |
| − | Comic number (plus one) is the latest, so don't show the buttons.
| |
| − | The spaces below are needed to make the other buttons look like they're centered even if a portion of the buttons are missing
| |
| − | -->| }}| }}<!--
| |
| − | --></ul></td></tr><!--
| |
| − | | |
| − | Now that the nav bar has been generated, display the rest if given.
| |
| − | | |
| − | Display the (optional) text just before the image
| |
| − | -->{{#if:|<tr><td style="padding-bottom:10px">{{{before}}}</td></tr>}}<!-- | |
| − | | |
| − | Almost done; just need to display the image, title text, and a bit more
| |
| − | --><tr><td><!--
| |
| − | | |
| − | {{{custom}}} will replace the image with whatever it contains if it exists
| |
| − | -->{{#if: |<!--
| |
| − | | |
| − | Now that we know we're not going to replace the image, let's display it if it exists
| |
| − | -->|{{#if:question_mark_2x.png|[[File:question_mark_2x.png|380x463px|Although now people will realize three-per-em space that all this time I've been using weird medium mathematical space whitespace characters in my hair space hair space hair space speech dot dot dot...]]}}}}<!--
| |
| − | | |
| − | {{{imagesize}}} will allow the comic to be shrunk if it's especially large
| |
| − | | |
| − | {{{noexpand}}} will hide the "Click comic to enlarge" notice
| |
| − | -->{{#ifeq:true|true||
| |
| − | {{#if:380x463px|<br />[Click comic to enlarge]}}
| |
| − | }}<!--
| |
| − | | |
| − | Add the title text underneath the comic.
| |
| − | --><br /><span style="margin-top: 0.9em; margin-bottom: {{#if:|0.5|0}}em; display:inline-block; font-size: 120%; <!--
| |
| − | Use the custom Title Text STYLE (ttstyle) if given
| |
| − | -->"><span class="plainlinks" title=""><!--
| |
| − | -->''[[Title text|Title text]]:''</span> {{#if:Although now people will realize three-per-em space that all this time I've been using weird medium mathematical space whitespace characters in my hair space hair space hair space speech dot dot dot...|Although now people will realize three-per-em space that all this time I've been using weird medium mathematical space whitespace characters in my hair space hair space hair space speech dot dot dot...|[[:Category:No title text|none]]}}<!--
| |
| − | --></span></td></tr><!--</table>
| |
| − | | |
| − | Ok, the upper navigation bar is done! Now, let's make the lower WHITE navbar.
| |
| − | You probably haven't seen this, check out comic [[10]] and others.
| |
| − | This is only displayed if {{{ognumber}}} is specified, otherwise it's replaced by the "gray" navbar (we'll make it below).
| |
| − | This table will contain a table row (tr) and cell (td)
| |
| − | --><tr><td><!--
| |
| − | | |
| − | Now make an unordered list which will display as the navigation bar
| |
| − | --><ul style="text-align: center; margin-top:2px; margin-bottom:{{#if:|20px|10px}};" class="no-link-underline"><!--
| |
| − |
| |
| − | Generate the |< and prev buttons, but only if {{{ognumber}}} IS GIVEN and is not 1
| |
| − | -->{{#if:|{{#ifexpr:1!=1<!--
| |
| − | | |
| − | {{{ognumber}}} is given and not 1, so make a list item and put a button in it that links to #7
| |
| − | -->|<li style="background-color: #FFFFF;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | | |
| − | Now link to #7. Why #7 and not #1? → see [[LiveJournal]]
| |
| − | -->[[7: Girl sleeping (Sketch -- 11th grade Spanish class)|<span style="color: #6E7B91; padding: 0 12px; white-space: nowrap;" title="">|<</span>]]</li><!--
| |
| − | | |
| − | Let's make the back button!
| |
| − | PIPE REMOVED--><li style="background-color: #FFFFF;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | | |
| − | Link to the previous comic
| |
| − | -->[[<span style="color:red">ERROR: PREVIOUS NUMBER MISSING.<br><br>PLEASE ADD <code><nowiki>|OGPREV=NUMBER</nowiki></code> TO THE PAGE!<br><br> </span>|<span style="color: #6E7B91; padding: 0 12px;" title="">< Prev #{{{ogprev}}}</span>]]</li><!--
| |
| − | | |
| − | {{{ognumber}}} is 1, so let's put non-breaking spaces here
| |
| − | -->| <!--
| |
| − | | |
| − | Close up shop-->}}}}<!--
| |
| − | | |
| − | Since we have {{{ognumber}}}, we need to say the original comic number at the center.
| |
| − | -->{{#if:|<!--{{#ifexpr:{{{ognumber|1}}}!=1|--><!--
| |
| − | | |
| − | Ok {{ognumber}} is not 1, go wild!
| |
| − | --><li style="background-color: #FFFFFF;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;" class="plainlinks"><!--
| |
| − | | |
| − | Depending on whether {{{ognumber}}} is 1 or not, toggle between using wide link mode or number link mode.
| |
| − | Wide link mode requires {{{lappend}}} to be set, while {{{ldomain}}} can default to www
| |
| − | --><!--
| |
| − | NOT USING THESE - [{{#ifexpr:{{{number|-1}}}>=1
| |
| − | NOT USING THESE - Comic number is probably valid, use number link mode
| |
| − | |https://xkcd.com/{{{number}}}
| |
| − | NOT USING THESE - Comic number is invalid or doesn't exist, use wide link mode
| |
| − | |https://{{{ldomain|www}}}.xkcd.com/{{{lappend}}}}} (This would need another two curly because added another IF statement)
| |
| − | | |
| − | Ok now generate the number, with ognote if it exists, or else it defaults to "(Original Order)"
| |
| − | -->[[LiveJournal#G|<span style="color: #6E7B91; padding: 0 12px;" title="Click to learn why the original xkcd comics were in a different order!"><!--
| |
| − |
| |
| − | Add ognote in parenthesis
| |
| − | --># {{#if:|({{#replace:{{{ognote}}}| | }})|(Original Order)}}<!-- Comic #{{{ognumber|}}} <u>(Original order)</u>
| |
| − | --></span>]]}}</li><!--
| |
| − | | |
| − | Now make the next and >| buttons, provided the {{{ognumber}}} exists
| |
| − | -->{{#ifexist:{{#expr:-2+1}}<!--
| |
| − | | |
| − | Check if this is 55 (which is the latest LiveJournal comic). If it is 55, then don't display the "Next" and >| buttons.
| |
| − | Why #52 and not #LATESTCOMIC? → see [[LiveJournal]]
| |
| − | -->|{{#ifexpr:52-1>0<!--
| |
| − | | |
| − | {{ognumber}} IS NOT 52, generate the Next and >| buttons
| |
| − | -->|<li style="background-color: #FFFFF;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | -->[[<span style="color:red"><br><br>ERROR: NEXT NUMBER MISSING.<br><br>PLEASE ADD <code><nowiki>|OGNEXT=NUMBER</nowiki></code> TO THE PAGE!<br><br> </span>|<span style="color: #6E7B91; padding: 0 12px;" title="">#{{{ognext}}} Next ></span>]]</li><!--
| |
| − | | |
| − | Make a button that points to 55 (which is the latest LiveJournal comic)
| |
| − | --><li style="background-color: #FFFFF;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | -->[[55: Useless{{!}}<span style="color: #6E7B91; padding: 0 12px; white-space: nowrap;" title="">>|</span>]]</li><!--
| |
| − | | |
| − | Comic number (plus one) is the latest, so don't show the buttons
| |
| − | The spaces below are needed to make the other buttons look like they're centered even if a portion of the buttons are missing
| |
| − | -->| }}|}}</ul></td></tr><!--
| |
| − | | |
| − | Ok, that row's done. But it'll be hidden if the comic is one of the first xkcd comics.
| |
| − | So, let's make the lower GRAY row. This is hidden if {{{ognumber}}} is specified, because it's replaced by the "white" navbar above.
| |
| − | This will be shown on almost all comics.
| |
| − | This table will contain a table row (tr) and cell (td)
| |
| − | -->{{#ifexist: {{{ognumber}}} | <!-- If ognumber is provided, hide the entire block, if not show it
| |
| − | -->|<tr><td><!--
| |
| − | | |
| − | Now make an unordered list which will display as the navigation bar
| |
| − | --><ul style="text-align: center; margin-top:-7px; margin-bottom:15px;" class="no-link-underline"><!-- CHATG
| |
| − | | |
| − | Generate the |< and prev buttons, but only if {{{number}}} exists and is greater than 1
| |
| − | -->{{#ifexpr:3143>1<!--
| |
| − | | |
| − | {{{number}}} is greater than 1; make a list item and put a button in it that links to #1
| |
| − | -->|<li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | link to #1
| |
| − | -->[[1: Barrel - Part 1|<span style="color: #FFFFFF; padding: 0 12px; white-space: nowrap;" title="">|<</span>]]</li><!--
| |
| − | | |
| − | We're not done here yet, let's make the back button
| |
| − | --><li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | | |
| − | Link to the previous comic
| |
| − | -->[[{{#expr:3143-1}}|<span style="color: #FFFFFF; padding: 0 12px;" title="">< Prev</span>]]</li><!--
| |
| − | | |
| − | If {{{number}}} is valid, we need to make the RANDOM COMIC LINK in the center
| |
| − | --><li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;" class="plainlinks"><!--
| |
| − | | |
| − | Generate the RANDOM COMIC LINK in the center.
| |
| − | The "Category:All pages" includes all comics, including the extra ones.
| |
| − | -->[[Special:RandomInCategory/All pages|<span style="color: #FFFFFF; padding: 0 12px;" title=""><!--
| |
| − | -->Random Explanation</span>]]</li><!--
| |
| − | | |
| − | Now make the next and >| buttons, provided the comic number exists
| |
| − | -->{{#ifexist:{{#expr:3143+1}}<!--
| |
| − | | |
| − | Check if this is the LATESTCOMIC. If it is, then don't display the "Next" and >| buttons.
| |
| − | -->|{{#ifexpr:{{LATESTCOMIC}}-3143>0<!--
| |
| − | | |
| − | Comic number is not the latest, so generate the Next and >| buttons
| |
| − | -->|<li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | -->[[{{#expr:3143+1}}{{!}}<span style="color: #FFFFFF; padding: 0 12px;" title="">Next ></span>]]</li><!--
| |
| − | | |
| − | Make a button that points to LATESTCOMIC (which is of course the latest comic)
| |
| − | --><li style="background-color: #6E7B91;
| |
| − | border: 1.5px solid #333333; border-radius: 3px 3px 3px 3px; box-shadow: 0 0 5px 0 gray;
| |
| − | display: inline; font-size: 16px; font-variant: small-caps; font-weight: 600;
| |
| − | margin: 0 4px; padding: 1.5px 0;"><!--
| |
| − | -->[[{{LATESTCOMIC}}{{!}}<span style="color: #FFFFFF; padding: 0 12px; white-space: nowrap;" title="">>|</span>]]</li><!--
| |
| − | | |
| − | Instead here the comic number (plus one) is the latest, so don't show the Next buttons (there are no next comics)
| |
| − | The spaces below are needed to make the other buttons look like they're centered even if a portion of the buttons are missing
| |
| − | -->| }}| }}<!--
| |
| − |
| |
| − | Here {{{number}}} doesn't exist or is less than 1; just put nothing here
| |
| − | -->|}}<!--
| |
| − | --></ul></td></tr>}}</table><!--
| |
| − | | |
| − | Add the comics to the automatic categories.
| |
| − | | |
| − | Put this page in categories by number. The padding ensures that #9 comes before #10
| |
| − | It otherwise sorts 'alphanumerically'; since the first character of "10" is "1", it would normally be placed before "9" even though it should be placed after
| |
| − | The padding turns each into 0009 and 0010 etc. Now, since "0" is less than "1", #9 gets sorted before #10.
| |
| − | -->{{#ifexpr:3143>=1|{{DEFAULTSORT: {{padleft:3143|4}}}}|<!--
| |
| − | -->}}<!--
| |
| − | | |
| − | Only categorise if the page is in the main namespace
| |
| − | -->{{#ifeq:{{NAMESPACE}}|{{ns:0}}<!--
| |
| − | | |
| − | Don't try to categorise the Main Page nor the extra comics
| |
| − | -->|{{#ifeq:{{FULLPAGENAME}}|{{int:mainpage}}||{{#ifeq:|yes|[[Category:Extra comics]][[Category:All pages]]|<!--
| |
| − | | |
| − | Alright, start putting it in the appropriate date categories
| |
| − | -->[[Category:All comics]][[Category:All pages]]<!--
| |
| − | -->{{#if:September 17, 2025|[[Category:Comics from {{#time:Y|September 17, 2025}}]] <!-- Years
| |
| − | -->[[Category:Comics from {{#time:F|September 17, 2025}}]] <!-- Months
| |
| − | -->[[Category:{{#time:l|September 17, 2025}} comics]] <!-- Weekdays
| |
| − | -->}}}}}}|}}<!--
| |
| − | -->
| |
| | | | |
| | ==Explanation== | | ==Explanation== |