View source for Module:Yesno

From the Dyson Sphere Program Wiki

You do not have permission to edit this page, for the following reasons:

  • The action you have requested is limited to users in one of the groups: Administrators, verified, trusted.
    Sign up or Log in to edit a page.
    The DSP Wiki is made by people like you! Anyone can edit and improve any pages.
  • You must confirm your email address before editing pages. Please set and validate your email address through your user preferences.
  • Your username or IP address has been automatically blocked by MediaWiki. The reason given is:
    Your IP address is listed as an open proxy in the DNSBL used by DSP Wiki.
    • Start of block: 03:03, 11 April 2025
    • Expiration of block: infinite
    • Intended blockee: 3.21.75.162
    Your current IP address is 3.21.75.162. Please include all above details in any queries you make.

You can view and copy the source of this page.

-- Imported from: https://en.wikipedia.org/wiki/Module:Yesno
-- Function allowing for consistent treatment of boolean-like wikitext input.
-- It works similarly to the template {{yesno}}.
return function (val, default)
-- If your wiki uses non-ascii characters for any of "yes", "no", etc., you
-- should replace "val:lower()" with "mw.ustring.lower(val)" in the
-- following line.
val = type(val) == 'string' and val:lower() or val
if val == nil then
return nil
elseif val == true
or val == 'yes'
or val == 'y'
or val == 'true'
or val == 't'
or val == 'on'
or val == 'ja'
or tonumber(val) == 1
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
000
1:0
Debug console
* The module exports are available as the variable "p", including unsaved modifications. * Precede a line with "=" to evaluate it as an expression or use print(). Use mw.logObject() for tables. * Use mw.log() and mw.logObject() in module code to send messages to this console.

Template used on this page:

Return to Module:Yesno.

🍪 We use cookies to keep session information to provide you a better experience.