第1行: |
第1行: |
| == Parsoid == | | == Parsoid == |
| * 要使得'''Parsoid'''在LNMP 1.7环境安装包下顺利使用可视化编辑功能需要进行如下修改: | | * 要使得'''Parsoid'''在LNMP 1.7环境安装包下顺利使用可视化编辑功能需要进行如下修改: |
− | # 注释掉<code>/usr/local/nginx/conf/enable-php.conf</code>中的<code>#try_files $uri =404;</code>; | + | # <s>注释掉<code>/usr/local/nginx/conf/enable-php.conf</code>中的<code>#try_files $uri =404;</code>;</s> |
| # 注释掉<code>/usr/local/php/etc/php.ini</code>中的<code>; cgi.fix_pathinfo=0</code>; | | # 注释掉<code>/usr/local/php/etc/php.ini</code>中的<code>; cgi.fix_pathinfo=0</code>; |
| # 与数据库无关,重启nginx和php-fpm即可。 | | # 与数据库无关,重启nginx和php-fpm即可。 |
第50行: |
第50行: |
| $wgPdftoText = '/usr/bin/pdftotext'; | | $wgPdftoText = '/usr/bin/pdftotext'; |
| </syntaxhighlight> | | </syntaxhighlight> |
− | == Semantic MediaWiki == | + | * 在迁移时发现<code>pdfinfo pdftotext</code>不安装亦可正常使用。 |
| + | == Extension:Semantic MediaWiki == |
| 在使用新版本Composer更新SMW时,Composer会提示报错<code> Package::setProvides must be called with a map of lowercased package name.</code>。目前找到的解决方法是使用旧版Composer(如版本2.1.14)进行更新。<ref>[https://sourceforge.net/p/semediawiki/mailman/message/37408313/ <nowiki>[Semediawiki-user]Problem installing SMW: composer complains about lowercased package names</nowiki>]</ref>如果遇到莫名其妙的包 冲突/丢失 的问题,可以尝试更换composer的源。 | | 在使用新版本Composer更新SMW时,Composer会提示报错<code> Package::setProvides must be called with a map of lowercased package name.</code>。目前找到的解决方法是使用旧版Composer(如版本2.1.14)进行更新。<ref>[https://sourceforge.net/p/semediawiki/mailman/message/37408313/ <nowiki>[Semediawiki-user]Problem installing SMW: composer complains about lowercased package names</nowiki>]</ref>如果遇到莫名其妙的包 冲突/丢失 的问题,可以尝试更换composer的源。 |
| <references /> | | <references /> |
| + | == Extension:VisualEditor == |
| + | ; 此章节仅针对'''旧版VisualEditor''',新版MediaWiki(1.35版本起)已内置相关组件无需额外安装。 |
| + | * [[mw:Extension:VisualEditor|Extension:VisualEditor]]根据章节[[mw:Extension:VisualEditor#Linking_with_Parsoid_in_private_wikis|Linking with Parsoid in private wikis]],添加了[[mw:Talk:Parsoid/Archive#Installing_on_a_private_wiki|Installing on a private wiki]]中的内容,使其在本Wiki下可用。 |
| + | * 本Wiki目前已使用[[mw:Extension:NetworkAuth|Extension:NetworkAuth]],对于来自Parsoid的访问进行自动登录,相关配置如下: |
| + | <div class="mw-collapsible mw-collapsed"><syntaxhighlight lang="php"> |
| + | //弃用的配置 |
| + | if ( $_SERVER['REMOTE_ADDR'] == 'SERVER-IP' ) { |
| + | $wgGroupPermissions['*']['read'] = true; |
| + | $wgGroupPermissions['*']['edit'] = true; |
| + | } |
| + | //启用的配置 |
| + | require_once "$IP/extensions/NetworkAuth/NetworkAuth.php"; |
| + | $wgNetworkAuthUsers[] = [ |
| + | 'iprange' => [ 'SERVER-IP', |
| + | '127.0.0.1' ], |
| + | 'user' => 'Aria-bot', |
| + | ]; |
| + | </syntaxhighlight></div> |
| | | |
| + | * Parsoid服务的单服务器多站点的示例配置内容(位于<code>/etc/mediawiki/parsoid/config.yaml</code>)建议拷贝源代码: |
| + | <div class="mw-collapsible mw-collapsed"><syntaxhighlight lang="yaml"> |
| + | worker_heartbeat_timeout: 300000 |
| + | |
| + | logging: |
| + | level: info |
| + | |
| + | services: |
| + | - module: ../src/lib/index.js |
| + | entrypoint: apiServiceWorker |
| + | conf: |
| + | mwApis: |
| + | - # 1st |
| + | uri: 'http://www.kanade.win/api.php' |
| + | domain: 'www.kanade.win' |
| + | - # 2nd |
| + | uri: 'http://pool.kanade.win/api.php' |
| + | domain: 'pool.kanade.win' |
| + | - # 3rd |
| + | uri: 'http://test.kanade.win/api.php' |
| + | domain: 'test.kanade.win' |
| + | |
| + | </syntaxhighlight></div> |
| == 其他 == | | == 其他 == |
| | | |
| ==== 语言 ==== | | ==== 语言 ==== |
| 修改界面语言时,用户语言 要与 维基使用语言 保持一致;否则会出现奇怪的情况。但是现在这两个选项在配置文件中设置成一样的,也隐藏了前台的修改选项。 | | 修改界面语言时,用户语言 要与 维基使用语言 保持一致;否则会出现奇怪的情况。但是现在这两个选项在配置文件中设置成一样的,也隐藏了前台的修改选项。 |