Editing Module:BSW/MainPage
From the only original and legitimate Battlestar Wiki: the free-as-in-beer, non-corporate, open-content encyclopedia, analytical reference, and episode guide on all things Battlestar Galactica. Accept neither subpar substitutes nor subpar clones.
More actions
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
| Latest revision | Your text | ||
| Line 64: | Line 64: | ||
-- ── welcome() ──────────────────────────────────────────────────── | -- ── welcome() ──────────────────────────────────────────────────── | ||
-- Welcome band at the top of the main page. | |||
-- Logo, wiki name, one-line description, article count. | |||
function p.welcome( frame ) | function p.welcome( frame ) | ||
local articles | local articles = mw.site.stats.articles | ||
local formatted = tostring( articles ):reverse():gsub( '(%d%d%d)', '%1,' ):reverse():gsub( '^,', '' ) | local formatted = tostring( articles ):reverse():gsub( '(%d%d%d)', '%1,' ):reverse():gsub( '^,', '' ) | ||
local inner = | local inner = | ||
'<div class="bsw-welcome-logo">' .. | '<div class="bsw-welcome-logo">' .. | ||
'<img src="https://en.battlestarwiki.org/resources/BSGWIKILOGO.png" ' .. | |||
'alt="Battlestar Wiki" width="48" height="48">' .. | |||
'</div>' .. | |||
'<div class="bsw-welcome-text">' .. | '<div class="bsw-welcome-text">' .. | ||
'<div class="bsw-welcome-title">Battlestar Wiki</div>' .. | '<div class="bsw-welcome-title">Battlestar Wiki</div>' .. | ||
'<div class="bsw-welcome-desc">' .. | '<div class="bsw-welcome-desc">' .. | ||
'The free, non-corporate encyclopedia on all things ' .. | |||
'<i>Battlestar Galactica</i> \226\128\148 ' .. | |||
formatted .. '\194\160articles and counting.' .. | |||
'</div>' .. | |||
'</div>' .. | '</div>' .. | ||
'<div class="bsw-welcome-links">' .. | '<div class="bsw-welcome-links">' .. | ||