Toggle menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:FeaturedPage: Difference between revisions

Template page
No edit summary
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
<div class="bob">
<noinclude>Current featured article: </noinclude>{{#switch:{{#expr: ({{CURRENTDAY}} + (({{#time:s}} * 3) mod 8) * {{#time:s}} + (({{#time:s}} + 6) mod 5) * ({{CURRENTWEEK}} and 14)) mod 4}}|
<div class="bob-header mw-no-invert">
0=Montego Bay|
{{PAGENAME}}
1=Bayview|
</div>
2=Alexandria|
<div class="bob-info">
3=2024 North City Elections|
test
4=Crystal Bay|
</div>
}}
</div>
 
---
<noinclude>List of all featured blurbs: [[:Category:FeaturedBlurbs]].
 
To add articles, just add them to the list and increase the last Modulo operation by the number of articles you added.
 
This will change content at least every hour. If the seconds are uneven while the site is being cached, it will add the seconds as offset to the hours, else it will add the current week and 3 for randomness. Remember, this is time of caching, so it has to be done at least once an hour.</noinclude><noinclude>[[Category:TCRF templates]]</noinclude>

Latest revision as of 03:55, 20 September 2024

Current featured article: Bayview

List of all featured blurbs: Category:FeaturedBlurbs.

To add articles, just add them to the list and increase the last Modulo operation by the number of articles you added.

This will change content at least every hour. If the seconds are uneven while the site is being cached, it will add the seconds as offset to the hours, else it will add the current week and 3 for randomness. Remember, this is time of caching, so it has to be done at least once an hour.