dev

This page, or parts of it, are still untranslated. Please translate it to the appropriate language (中文(简体)).

AutoCreateUserPages 允许在你至少贡献过一次的wiki上自动创建你自己的用户页面和讨论页,无论是通过编辑还是发布消息、评论或讨论帖子。它最初是出于个人用途而制作的,但是,许多wiki开始在网站上使用它来代替欢迎工具。

Installation

Configuration

此脚本的配置选项存储在全局window.AutoCreateUserPagesConfig对象。以下选项可用:

The script also fires a AutoCreateUserPages.loaded hook when all pages are created, with the array of created page names as the argument, in case developers want to execute further actions on these after their creation.

Example

The following configuration, for a user named User1, will create pages User:User1 and User talk:User1 (on a wiki with talkpages enabled) once they make their first edit or post, where the userpage will be created with {{:w:User:User1}} and the talkpage will be created with {{:w:User:User1/talk}}, and the user will be notified with a link to their userpage. The summary used when creating the page will be "Creating my pages".

window.AutoCreateUserPagesConfig = {
    content: {
        2: '{{:w:User:User1}}',
        3: '{{:w:User:User1/talk}}'
    },
    summary: '创建我的页面',
    notify: '<a href="/wiki/User:$2">这里有一个到您的用户页面链接,$1!</a>'
};