Fandom Developers Wiki
Advertisement

此頁面或部分內容仍未翻譯,請將其翻譯成適當的語言(中文(繁體))

用戶的帳戶年齡(UserAccountAge)提供了以附加用戶標籤的方式在Oasis版面的個人檔案列出特定帳戶的年齡。這個腳本源於English WikipediaPleaseStand的用戶頁面上的隨機化和簡單化。當您點擊此用戶標籤,它會連接至JSON數據格式並顯示自帳戶創建的天數。 (示例)

It was initially conceived as a "Fandomization" and simplification of PleaseStand's UserInfo script on the English Wikipedia, though the most recent iteration of the script, namely code2.js, instead employs the jQuery timeago plugin, removing the hacky attempts at formatting fuzzy dates and opening the script up to a wider variety of user languages. Furthermore, the formatted date of account creation is now displayed upon cursor hover over the user tag.

有時候,對於一些較舊的帳戶(2005或更早以前),MediaWiki的API會將用戶的註冊日期返回至"null"值,因此在個人檔案上將不會顯示用戶標籤。

安裝方法[]

Users can customize the format of the date shown in the tag via the inclusion of window.customUserAccountAge object. Setting the showFullDate boolean to true will coerce the script into displaying the formatted account creation date in place of the more general "fuzzy date" that is displayed by default. An example config object is shown below:

window.customUserAccountAge = {
	showFullDate: true
};

更改紀錄[]

18-04-22
Addition of support for Gamepedia wikis
08-10-21
Final UCP update; removal of legacy MW 1.19 code, reinstitution of fuzzy dates for values beyond 30 days, addition of user config option for full dates
29-07-20
Addition of fix to UCP lazy-load masthead detection mechanism, cleanup
05-07-20
Rewrite to support usage on UCP wikis
02-11-17
Removal of unused usercontribs query, minor edits to user tag link
17-09-17
Replacement of PleaseStand code in favor of timeago plugin
17-02-17
Bug fix for usernames with special characters
16-02-17
Initial revision
Advertisement