After working for a bit on it, I've the featured article section of the main page randomly showing various featured articles. The next step is for the admin to determine the list of articles to feature.

I noticed these featured articles blurbs don't count as articles because embedding them uses templates. It's kind of a shame, IMHO, as this wikia has more than the 166 pages on it. Yeah, I can understand why they don't count templates and I agree, but when a template acts like an article, well, shouldn't it count as an article? Guess not. . . .

Anyway, how does it work? I'll save you the time of editing the main page, locating the code, etc. Here it is:

{{#switch: {{random|1|4|edit=no|talk=no}}
| 1 = <big>{{MP/FA}}</big><br /><br />
| 2 = <big>{{MP/FB}}</big><br /><br />
| 3 = <big>{{MP/FC}}</big><br /><br />
| 4 = <big>{{MP/FD}}</big><br /><br />
| is in error }}.

I also added then random template (found in the non-included Wikia templates), as well as the MP/FB, MP/FC, MP/FD templates. If there is a better way of doing this I'm open to learning it and using it, BTW. How does the random template work? Well, let's see:

{{#expr:{{#expr:{{CURRENTTIMESTAMP}} mod {{#expr:{{{2|50}}} - {{{1|0}}} + 1}}}} + {{{1|0}}}}}

If the above doesn't mean a lot to you, basically, you take the current TOD and determine the modulo of it based upon the variables passed by the caller (e.g. 1|4 or 105|110). If you're not familiar with modulo math, well, maybe you are if you use A.M. and P.M. The 12 hour clock uses modulo 12 math. There are 24 hours in a day, but many people (especially in the U.S.A.) don't think in 24 hours. They think in A.M. and P.M. Ah, you see (I think)! Modulo is the remainder left over when you subtract the largest multiple that is smaller than the number you're considering.

For example: To determine 458 mod 7, you divide 458 by 7 and get a reminder of 3, which is mod number (458 - (65*7=455) = 3). Ah, you might be saying OK, I understand remainders equal mod. So, back to the 12 hour clock, OK, I see. 14:00 = 1 = P.M. with a remainder of 2 so 2 P.M. = 14:00.

All right! I know many of you are going, I.B.Halliwell is crazy! Why is he taking so long to explain such a simple and easy concept and let alone so easy as European and U.S.A. time!

I took the long way because I had this exact same conversation with both young kid (some in the Scan2Go age range) and older people (like my 85 year old Mother). Sometimes people use a mathematical concept without realizing:

  • They are using it and
  • How it really works!

Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.