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

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.
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
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 = mw.site.stats.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 logo = frame:preprocess( '[[File:BSG-WIKI SM.png|40px|link=Main Page|alt=Battlestar Wiki]]' )
    local desc = frame:preprocess(
        "The free, non-corporate encyclopedia on all things " ..
        "''Battlestar Galactica'' \226\128\148 " ..
        formatted .. "\194\160articles and counting."
    )


     local inner =
     local inner =
         '<div class="bsw-welcome-logo">' .. logo .. '</div>' ..
         '<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">' .. desc .. '</div>' ..
         '<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">' ..

To edit this page, please enter the words that appear below in the box (more info):

Refresh
Cancel Editing help (opens in new window)

  [] · [[]] · [[|]] · {{}} · · “” ‘’ «» ‹› „“ ‚‘ · ~ | ° &nbsp; · ± × ÷ ² ³ ½ · §
     [[Category:]] · [[:File:]] · [[Special:MyLanguage/]] · <code></code> · <nowiki></nowiki> <code><nowiki></nowiki></code> · <syntaxhighlight></syntaxhighlight> · <includeonly></includeonly> · <noinclude></noinclude> · #REDIRECT[[]] · <translate></translate> · <languages/> · {{#translation:}} · <tvar|></> · {{DEFAULTSORT:}} · <categorytree></categorytree> · <div style="clear:both;"></div> <s></s>


Your changes will be visible immediately.
  • For testing, please use the sandbox instead.
  • On talk pages, please sign your comment by typing four tildes (~~~~).

Page included on this page: