Follow urlmanager and query in Yiiframework 2.0 with example
- Yii :: $ app-> basePath **** → → **** D: \ wamp \ www \ yiiframework2.0 \ project \ backend
- Yii :: $ app-> homeUrl; **** → → **** / yiiframework2.0 / project / backend / web / index.php
- Yii :: $ app-> getUrlManager () → createUrl ('user) **** → → **** / yiiframework2.0 / project / backend / web / index.php? R = user
- Yii :: $ app-> urlManager-> createUrl (['site / page,' id => 'about]) **** → → ****
/ yiiframework 2.0 / project / backend / web / index.php? r = site% 2Fpage & id = about
- Yii :: $ app-> urlManager-> createUrl (['site / view,' id => 105]) **** → → **** / yiiframework2.0 / project / backend / web / index.php? r = site% 2Fview & id = 105
- Yii :: $ app-> request-> baseUrl **** → → **** / yiiframework2.0 / project / backend / web
- Yii :: $ app-> request-> url **** → → ****
/ yiiframework 2.0 / project / backend / web / index.php
source share