_kai
(_kai_)
1
I have seen here, for example, https://github.com/yiisoft/yii2/blob/master/framework/rbac/DbManager.php things like:
[[db]]
or
public $itemTable = '{{%auth_item}}';
in comments and even in the code and I wonder what those symbols means.
Thanks
Bizley
(Bizley)
2
First is used in comments to generate documentation with the proper linked item (see your example here http://www.yiiframework.com/doc-2.0/yii-rbac-dbmanager.html )
Second is the way to write database table name so it will be automatically prefixed with the proper configured string.
_kai
(_kai_)
3
Thanks for replying Bizley.
When you say "generate documentation" you mean PHPDoc, is that right?
And where do I setup the prefix for the database tables?
Thanks man
Bizley
(Bizley)
4
I’m not sure but I don’t think so. PhpDocs links are made with @link, at least the version I know.
This is for http://www.yiiframework.com/doc-2.0/ext-apidoc-index.html
As for the prefix - this is the parameter to set http://www.yiiframework.com/doc-2.0/yii-db-connection.html#$tablePrefix-detail
Raoul
(Manu34)
5
Hi,
the notation [[db]] is used by the yii2-apidoc extension to create links between the generated guide and the generated API Documentation.
Check the [size="2"]Yii2 Core framework code style.

[/size]