If i need add links to frontend stuff from backend part in menu(or from backend to admin), how i can do this without hardcode? This:
\Yii::$app->request->BaseUrl
returns path from parents dir
/sitename/backend/web
/sitename/frontend/web
If i need add links to frontend stuff from backend part in menu(or from backend to admin), how i can do this without hardcode? This:
\Yii::$app->request->BaseUrl
returns path from parents dir
/sitename/backend/web
/sitename/frontend/web
My mistake - I was incorrectly sent link value.
Wrong:
Thats Works:
In your backend application config you should add additional 'UrlManager' component with different name and configuration equals to the one used at front end application:
Then you should invoke following to compose front-end URL: