<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="zh-Hans-CN">
	<id>https://wiki.statsape.com/index.php?action=history&amp;feed=atom&amp;title=%E6%A8%A1%E5%9D%97%3ACiteStatsape</id>
	<title>模块:CiteStatsape - 版本历史</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.statsape.com/index.php?action=history&amp;feed=atom&amp;title=%E6%A8%A1%E5%9D%97%3ACiteStatsape"/>
	<link rel="alternate" type="text/html" href="https://wiki.statsape.com/index.php?title=%E6%A8%A1%E5%9D%97:CiteStatsape&amp;action=history"/>
	<updated>2026-11-11T03:00:50Z</updated>
	<subtitle>本wiki上该页面的版本历史</subtitle>
	<generator>MediaWiki 1.39.6</generator>
	<entry>
		<id>https://wiki.statsape.com/index.php?title=%E6%A8%A1%E5%9D%97:CiteStatsape&amp;diff=2762&amp;oldid=prev</id>
		<title>2023年12月5日 (二) 09:49 Zeroclanzhang</title>
		<link rel="alternate" type="text/html" href="https://wiki.statsape.com/index.php?title=%E6%A8%A1%E5%9D%97:CiteStatsape&amp;diff=2762&amp;oldid=prev"/>
		<updated>2023-12-05T09:49:56Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;zh-Hans-CN&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;←上一版本&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;2023年12月5日 (二) 17:49的版本&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l39&quot;&gt;第39行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第39行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         santizedURL = mw.ustring.gsub( url, &amp;#039;www%.&amp;#039;, &amp;#039;&amp;#039; )&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         santizedURL = mw.ustring.gsub( url, &amp;#039;www%.&amp;#039;, &amp;#039;&amp;#039; )&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     else&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     else&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         -- Add &amp;quot;https://&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;robertsspaceindustries&lt;/del&gt;.com/&amp;quot; to url if it is not present&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         -- Add &amp;quot;https://&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;wiki.statsape&lt;/ins&gt;.com/&amp;quot; to url if it is not present&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         santizedURL = &amp;#039;https://wiki.statsape.com/&amp;#039; .. url&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         santizedURL = &amp;#039;https://wiki.statsape.com/&amp;#039; .. url&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     end&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     end&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l67&quot;&gt;第67行：&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;第67行：&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         type = &amp;#039;问题理事会&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         type = &amp;#039;问题理事会&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     elseif stringContains( &amp;#039;wiki.statsape.com&amp;#039;, url ) then&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     elseif stringContains( &amp;#039;wiki.statsape.com&amp;#039;, url ) then&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         type = &amp;#039;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;统计猿云智库&lt;/del&gt;&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         type = &amp;#039;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;决策链云智库&lt;/ins&gt;&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     else&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;     else&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         type = &amp;#039;文献链接&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;         type = &amp;#039;文献链接&amp;#039;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key statsape_wiki:diff::1.12:old-1271:rev-2762 --&gt;
&lt;/table&gt;</summary>
		<author><name>Zeroclanzhang</name></author>
	</entry>
	<entry>
		<id>https://wiki.statsape.com/index.php?title=%E6%A8%A1%E5%9D%97:CiteStatsape&amp;diff=1271&amp;oldid=prev</id>
		<title>2023年8月3日 (四) 07:55 Zeroclanzhang</title>
		<link rel="alternate" type="text/html" href="https://wiki.statsape.com/index.php?title=%E6%A8%A1%E5%9D%97:CiteStatsape&amp;diff=1271&amp;oldid=prev"/>
		<updated>2023-08-03T07:55:48Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新页面&lt;/b&gt;&lt;/p&gt;&lt;div&gt;local p = {}&lt;br /&gt;
local args&lt;br /&gt;
&lt;br /&gt;
--- Helper function checking if a substring is in a string&lt;br /&gt;
--&lt;br /&gt;
-- @param needle string - Value to search for&lt;br /&gt;
-- @param haystack string - String to search in&lt;br /&gt;
--&lt;br /&gt;
-- @return bool - True if found&lt;br /&gt;
local function stringContains( needle, haystack )&lt;br /&gt;
    return string.find( mw.ustring.lower( haystack ), needle, 1, true )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- Remove hyphen and format string into title case&lt;br /&gt;
--&lt;br /&gt;
-- @param title string&lt;br /&gt;
--&lt;br /&gt;
-- @return string&lt;br /&gt;
local function formatTitle( title )&lt;br /&gt;
    local titleCase = require( &amp;#039;Module:String2&amp;#039; ).title&lt;br /&gt;
    if title and title ~= &amp;#039;&amp;#039; then&lt;br /&gt;
        -- Replace hyphens with space&lt;br /&gt;
        title = string.gsub( title, &amp;#039;-&amp;#039;, &amp;#039; &amp;#039; )&lt;br /&gt;
        -- Format into title case&lt;br /&gt;
        title = titleCase{ args={ title } }&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    return title&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- @param url string&lt;br /&gt;
--&lt;br /&gt;
-- @return string&lt;br /&gt;
local function sanitizeURL( url )&lt;br /&gt;
    local santizedURL&lt;br /&gt;
&lt;br /&gt;
    if stringContains(&amp;#039;statsape.com&amp;#039;, url) then&lt;br /&gt;
        -- Remove &amp;#039;www.&amp;#039; from the link&lt;br /&gt;
        santizedURL = mw.ustring.gsub( url, &amp;#039;www%.&amp;#039;, &amp;#039;&amp;#039; )&lt;br /&gt;
    else&lt;br /&gt;
        -- Add &amp;quot;https://robertsspaceindustries.com/&amp;quot; to url if it is not present&lt;br /&gt;
        santizedURL = &amp;#039;https://wiki.statsape.com/&amp;#039; .. url&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    return santizedURL&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
--- Determine which type of RSI website it is&lt;br /&gt;
--&lt;br /&gt;
-- @param url string - RSI website URL&lt;br /&gt;
--&lt;br /&gt;
-- @return string - Site type or nil if unknown&lt;br /&gt;
local function getType( url )&lt;br /&gt;
    local type&lt;br /&gt;
    -- type后面接的就是引用列表里条目后显示的简短文字&lt;br /&gt;
    if stringContains( &amp;#039;/comm-link/&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;通讯链接&amp;#039;&lt;br /&gt;
    elseif stringContains( &amp;#039;/galactapedia/&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;银河百科&amp;#039;&lt;br /&gt;
    elseif stringContains( &amp;#039;/Spectrum/&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;光谱论坛&amp;#039;&lt;br /&gt;
    elseif stringContains( &amp;#039;/pledge/&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;Pledge Store&amp;#039;&lt;br /&gt;
    elseif stringContains( &amp;#039;/starmap&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;方舟星图&amp;#039;&lt;br /&gt;
    elseif stringContains( &amp;#039;/issue-council&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;问题理事会&amp;#039;&lt;br /&gt;
    elseif stringContains( &amp;#039;wiki.statsape.com&amp;#039;, url ) then&lt;br /&gt;
        type = &amp;#039;统计猿云智库&amp;#039;&lt;br /&gt;
    else&lt;br /&gt;
        type = &amp;#039;文献链接&amp;#039;&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    return type&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getSubtype( url, type )&lt;br /&gt;
    local subtype = nil&lt;br /&gt;
    if type == &amp;#039;Comm-Link&amp;#039; then&lt;br /&gt;
        subtype = string.match( url, &amp;#039;/comm%-link/([%w-]+)/%d+-[%w-]+&amp;#039; )&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    return formatTitle( subtype )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
local function getTitle( url, type )&lt;br /&gt;
    local titleText&lt;br /&gt;
    local throwError = function()&lt;br /&gt;
        return error( &amp;#039;Title can not be generated, please fill in the text parameter.&amp;#039; )&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    -- Auto title generation, might not be accurate since special characters&lt;br /&gt;
    -- are escaped in the URL&lt;br /&gt;
    --&lt;br /&gt;
    -- e.g. /comm-link/transmission/14710-Starfarer-Q-A-Part-1&lt;br /&gt;
    if type == &amp;#039;Comm-Link&amp;#039; then&lt;br /&gt;
        titleText = string.match( url, &amp;#039;/comm%-link/[%w-]+/%d+-([%w-]+)&amp;#039; )&lt;br /&gt;
        -- e.g. /article/0j46Lzl8xm-torral-aggregate&lt;br /&gt;
    elseif type == &amp;#039;Galactapedia&amp;#039; then&lt;br /&gt;
        titleText = &amp;#039;Galactapedia: &amp;#039; .. string.match( url, &amp;#039;/article/%w+-([%w-]+)&amp;#039; )&lt;br /&gt;
        -- NOTE: Only support threads at the moment&lt;br /&gt;
        -- e.g. /thread/star-citizen-alpha-3-13-0-live-7319707-patch-notes&lt;br /&gt;
    elseif type == &amp;#039;Spectrum&amp;#039; then&lt;br /&gt;
        titleText = string.match( url, &amp;#039;/thread/%w+-([%w-]+)&amp;#039; )&lt;br /&gt;
        -- e.g. /hc/en-us/categories/360000295274-Updates-and-Info&lt;br /&gt;
    elseif type == &amp;#039;Knowledge Base&amp;#039; then&lt;br /&gt;
        titleText = string.match( url, &amp;#039;/hc/.+/.+/%d+-([%w-]+)&amp;#039; )&lt;br /&gt;
        -- Will still try its best to extact a title&lt;br /&gt;
    else&lt;br /&gt;
        local urlParts = mw.text.split(url, &amp;#039;[/]&amp;#039;)&lt;br /&gt;
        titleText = urlParts[ #urlParts ]&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    return formatTitle( titleText )&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- NOTE: Don&amp;#039;t have internal link support yet&lt;br /&gt;
function p.main( frame )&lt;br /&gt;
    if args == nil then&lt;br /&gt;
        args = require( &amp;#039;Module:Arguments&amp;#039; ).getArgs( frame )&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    local url = sanitizeURL( args.url )&lt;br /&gt;
    local type = getType( url )&lt;br /&gt;
    local date = args.accessdate&lt;br /&gt;
    local title&lt;br /&gt;
    local output&lt;br /&gt;
&lt;br /&gt;
    if args.text then&lt;br /&gt;
        title = args.text&lt;br /&gt;
    else&lt;br /&gt;
        title = getTitle( url, type )&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    -- Maybe there is a smarter way?&lt;br /&gt;
    output = &amp;#039;&amp;lt;cite class=&amp;quot;citation rsi_site&amp;quot;&amp;gt;&amp;#039; ..&lt;br /&gt;
            &amp;#039;&amp;lt;span class=&amp;quot;metadata citation-icon&amp;quot; title=&amp;quot;RSI site&amp;quot;&amp;gt;[[File:StatsapeSite.svg|x11px|link=]]&amp;lt;/span&amp;gt;&amp;#039; ..&lt;br /&gt;
            &amp;#039;[&amp;#039; .. url .. &amp;#039; &amp;#039; .. title .. &amp;#039;]&amp;#039;&lt;br /&gt;
&lt;br /&gt;
    if type then&lt;br /&gt;
        local subtype = getSubtype( url, type )&lt;br /&gt;
&lt;br /&gt;
        output = output .. &amp;#039;. &amp;#039;&lt;br /&gt;
        if subtype then&lt;br /&gt;
            output = output .. &amp;#039;&amp;lt;i&amp;gt;&amp;#039; .. subtype .. &amp;#039;&amp;lt;/i&amp;gt; - &amp;#039;&lt;br /&gt;
        end&lt;br /&gt;
        output = output .. &amp;#039;&amp;lt;i&amp;gt;&amp;#039; .. type .. &amp;#039;&amp;lt;/i&amp;gt;&amp;#039;&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    if date then&lt;br /&gt;
        output = output .. &amp;#039;. Retrieved &amp;#039; .. date&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    return output&lt;br /&gt;
end&lt;br /&gt;
return p&lt;/div&gt;</summary>
		<author><name>Zeroclanzhang</name></author>
	</entry>
</feed>