如何在MediaWiki中创建与我们联系的页面

问题描述:

我想在我的mediawiki网站的联系我们页面中添加联系我们表单。我已经下载了联系我们的扩展名并将其放入扩展文件夹并将其包含在LocalSetting.php中文件如下如何在MediaWiki中创建与我们联系的页面

wfLoadExtension('ContactPage'); 
$wgContactConfig['default'] = array(
    'RecipientUser' => 'User', // Must be the name of a valid account 
    'SenderName' => 'Contact Form on ' . $wgSitename, // "Contact Form on" needs to be translated 
    'SenderEmail' => null, // Defaults to $wgPasswordSender, may be changed as required 
    'RequireDetails' => true, // Either "true" or "false" as required 
    'IncludeIP' => true, // Either "true" or "false" as required 
    'AdditionalFields' => array(
     'Text' => array(
      'label-message' => 'emailmessage', 
      'type' => 'textarea', 
      'rows' => 20, 
      'cols' => 80, 
      'required' => true, // Either "true" or "false" as required 
     ), 
    ), 
    // Added in MW 1.26 
    'DisplayFormat' => 'table', // See HTMLForm documentation for available values. 
    'RLModules' => array(), // Resource loader modules to add to the form display page. 
    'RLStyleModules' => array(), // Resource loader CSS modules to add to the form display page. 
); 

我正在使用mediawiki-1.25.1.But它不工作。

请帮忙。谢谢。

+1

它不起作用? – Tgr

分机ContactPage创建一个页面特别:联系人可以发送反馈,并且电子邮件的收件人是在第一个字段中指定的用户。如果有

$wgContactConfig['default'] = array(
    'RecipientUser' => 'WikiSysop', // Must be the name of a valid account 
    ... 
); 

指定了用户WikiSysop然后WikiSysop必须在他/她的帐户配置电子邮件和ContactPage将有发送电子邮件。

如果发送电子邮件有问题,则必须验证用户帐户是否有确认的电子邮件地址,并验证MediaWiki是否可以发送电子邮件(请参阅Manual:$wgSMTPother parameters)。