Extension:Comments
Comments Sürüm durumu: kararlı |
|
---|---|
Uygulama | Ayrıştırıcı uzantısı , Kanca |
Açıklama | Maddelere yorum yapılmasına izin veren <comments /> ayrıştırıcı kancası etiketi ekler |
Yazar(lar) |
|
En son sürüm | 4.6.0 (2019-08-08) |
MediaWiki | 1.31+ |
Veritabanı değişiklikleri | Evet |
Tablolar | Comments Comments_Vote Comments_block |
Lisans | GNU Genel Kamu Lisansı 2.0 veya üstü |
İndir | |
Örnek | Sosyal Araçlar Geliştirme Viki |
|
|
<comments /> |
|
|
|
Quarterly downloads | 52 (Ranked 87th) |
Translatewiki.net adresinde mevcutsa, Comments uzantısını çevirin | |
Sorunlar | Açık görevler · Hata bildir |
Comments uzantısı, etiketin bulunduğu makalelere yorum yapılmasına izin vermek için <comments />
ayrıştırıcı kancası etiketini ekler.
Yorum eylemleri "Special:Log/comments" ile kaydedilir, ancak varsayılan olarak gizlidirler, tıpkı devriye günlük girişleri gibi.
Yorum günlüğü girişlerini Special:RecentChanges olarak göstermek için $wgCommentsInRecentChanges = true;
ayarlayabilirsiniz (2.8+ sürümünde mevcuttur).
Kod düzeltmelerinin çoğu Misza ve Jack Phoenix olarak yapıldı.
Kurulum
- Dosyaları indirin ve
extensions/
klasörünüzdekiComments
adlı dizine yerleştirin.
Developers and code contributors should install the extension from Git instead, using:cd extensions/
git clone https://gerrit.wikimedia.org/r/mediawiki/extensions/Comments - LocalSettings.php dosyanızın altına aşağıdaki kodu ekleyin:
wfLoadExtension( 'Comments' );
- Bu uzantının ihtiyaç duyduğu gerekli veritabanı tablolarını otomatik olarak oluşturacak betik güncelleme komutunu çalıştırın.
- Yapıldı – Uzantının başarıyla yüklendiğini doğrulamak için vikinizde Special:Version seçeneğine gidin.
Kullanım
<comments />
— temel yorum formu, çoğu şey için yeterlidir.<comments allow="Derfel,Jack Phoenix,Misza" />
— yalnızca Derfel, Jack Phoenix ve Misza kullanıcılarının yorum göndermesine izin verir.<comments voting="Plus" />
— kullanıcıların yorumları olumsuz (başparmak aşağı) değerlendirmesini engeller ve yalnızca olumlu (başparmak yukarı) oylara izin verir.
Günün Yorumları
Uzantı ayrıca, varsayılan olarak "etkin olmayan" bir "Günün Yorumları" özelliğine (<commentsoftheday />
) sahiptir. Bu özelliği vikinin LocalSettings.php'sinde, require_once satırından sonra aşağıdakileri ekleyerek etkinleştirebilirsiniz:
require_once "$IP/extensions/Comments/CommentsOfTheDay.php";
nocache
argümanı ayrıştırıcı kancasına aktarılırsa (bunun gibi: <commentsoftheday nocache=true />
), ayrıştırıcı kancası memcached kullanmaz ve verileri önbellek yerine veritabanından alır. En güncel verileri göstermek istiyorsanız bu kullanışlıdır, ancak çok sunucu yoğun olabilir.
Kullanıcı hakları
Bu uzantı, üç yeni kullanıcı hakları ekler:
comment
(yorum göndermeye izin verir)commentlinks
(yorumlarda harici bağlantıların yayınlanmasına izin verir)commentadmin
(kullanıcı tarafından gönderilen yorumların silinmesine izin verir), ör.
$wgGroupPermissions['sysop']['commentadmin'] = true;
Varsayılan olarak, herkes, hatta anonim kullanıcılar bile yorum gönderebilir, ancak harici bağlantılar içeren yorumların yayınlanması autoconfirmed users ile sınırlıdır.
Anonim kullanıcıların harici bağlantılar gönderebilmesini istiyorsanız, bunu require_once
sonrası ekleyin:
$wgGroupPermissions['*']['commentlinks'] = true;
Varsayılan olarak, yalnızca commentadmin
grubundaki kullanıcılar yorumları silebilir.
Kullanıcı puanları
— amount of points to give out when another user gives "thumbs up" to your comment.$wgUserStatsPointValues['comment_plus']
— amount of points to give out when another user adds your comments to their ignore list (Special:CommentIgnoreList).$wgUserStatsPointValues['comment_ignored']
Parameters
— path to an image which will be displayed instead of an avatar if social tools (SocialProfile extension) aren't installed. Should be 50x50px. Note that there is no default avatar image shipped with this extension. The default is defined in$wgCommentsDefaultAvatar
and links to an external image onextension.json
server, an ad driven Wiki farm. You may prefer to set this parameter to point to a local file.shoutwiki.com
— by default, this variable is set to$wgCommentsInRecentChanges
false
. Set it totrue
to display comments log entries in Special:RecentChanges, too, in addition to the comments log at Special:Log/comments.
— by default, this variable is set to$wgCommentsSortDescending
false
. Set it totrue
to sort comments by date descending, with the new comment box and most recent comments at the top.
Magic words/Parser functions
Comments includes 2 magic words and a parser function:
{{NUMBEROFCOMMENTS}}
gives the entire number of comments on the wiki.{{NUMBEROFCOMMENTSPAGE}}
gives number of comments on the current page.{{NUMBEROFCOMMENTSPAGE:<pagename>}}
gives number of comments on the given page.
Hooks
Comments extension adds three hooks,
, Comment::add
and Comment::delete
.
Comment::isSpam
Hook name | When it is called | Parameters |
---|---|---|
|
After a comment has been added into the database, on the bottom of Comment::add function |
|
|
After a comment has been deleted and the caches have been purged (function delete on class Comment) |
|
|
Called in Comment::isSpam before performing other spam checks.
|
|
Uluslararasılaştırma
The Comments extension currently has (partial or full) support for 68 different languages, including English. Please visit translatewiki.net if you want to translate Comments into your language.
YAPILACAKLAR listesi
- HTML output is not valid XHTML - would be nice if it were but we can live without that
- Would be nice if there was a special page that gives a overview of all uses of the Comments extension on all pages (for an adminstrator to be able to moderate easier)
Ayrıca bakınız
- Stable extensions/tr
- Parser extensions/tr
- Hook extensions/tr
- GPL licensed extensions/tr
- Extensions in Wikimedia version control/tr
- ArticlePurge extensions/tr
- BeforeCreateEchoEvent extensions/tr
- LoadExtensionSchemaUpdates extensions/tr
- MagicWordwgVariableIDs extensions/tr
- ParserFirstCallInit extensions/tr
- ParserGetVariableValueSwitch extensions/tr
- All extensions/tr
- Social tools/tr
- Discussion and forum extensions/tr