i a new yii developer and i do not understand one thing. In common/config/params.php file, i have following code:
<?php
return [
'adminEmail' => 'admin@example.com',
'supportEmail' => 'support@example.com',
'user.passwordResetTokenExpire' => 3600,
'regions' => require __DIR__ . '/region.php',
];
what is the difference between 'regions' => require __DIR__ . '/region.php'
, and 'regions' => __DIR__ . '/region.php',
In 'regions' => __DIR__ . '/region.php'
regions
will contain a string variable (path to region.php based on current dir)
In 'regions' => require __DIR__ . '/region.php'
regions
will contain an object of region.php
class