Class yeesoft\comments\Comments

Inheritanceyeesoft\comments\Comments » yii\base\Module

Comments Module For Yii2 Framework

Public Methods

Hide inherited methods

MethodDescriptionDefined By
init() yeesoft\comments\Comments
registerTranslations() yeesoft\comments\Comments
renderUserAvatar() Render user avatar by UserID according to $userAvatar setting yeesoft\comments\Comments
t() yeesoft\comments\Comments

Constants

Hide inherited constants

ConstantValueDescriptionDefined By
DEFAULT_AVATAR '/images/user.png' Path to default avatar image yeesoft\comments\Comments
VERSION '0.1.0' Version number of the module. yeesoft\comments\Comments

Property Details

$captchaOptions public property
public array $captchaOptions = ['class' => 'yii\captcha\CaptchaAction''minLength' => 4'maxLength' => 6'offset' => 5]
$commentsAssetUrl public property
public string $commentsAssetUrl null
$commentsModuleID public property
public string $commentsModuleID 'comments'
$commentsPerPage public property
public int $commentsPerPage 5
$controllerNamespace public property
public string $controllerNamespace 'yeesoft\comments\controllers'
$deletedUserName public property
public string $deletedUserName 'DELETED'
$displayAvatar public property
public boolean $displayAvatar TRUE
$maxNestedLevel public property
public int $maxNestedLevel 5
$nestedOrderDirection public property

Const

public int $nestedOrderDirection SORT_ASC
$onlyRegistered public property
public boolean $onlyRegistered FALSE
$orderDirection public property

Const

public int $orderDirection SORT_DESC
$userAvatar public property
public string|callable $userAvatar null
$userModel public property
public string $userModel 'common\models\User'
$usernameBlackRegexp public property
public string $usernameBlackRegexp '/^(.)*admin(.)*$/i'
$usernameRegexp public property
public string $usernameRegexp '/^(\w|\d|_|\-| )+$/'

Method Details

init() public method

public void init ( )
registerTranslations() public method

public void registerTranslations ( )
renderUserAvatar() public method

Render user avatar by UserID according to $userAvatar setting

public string renderUserAvatar ( $user_id )
$user_id int
t() public static method

public static void t ( $category, $message, $params = [], $language null )
$category
$message
$params
$language