M
M
Maxim2014-05-02 11:14:14
Yii
Maxim, 2014-05-02 11:14:14

How to set paths to resources (assets) on subdomains in yii?

The situation is this, the site has dynamic subdomains that are processed by one controller.
When loading a widget, for example CLinkPager, it includes .css, like subdomain.site.com/assets/hash/style.css, this file, like the folder, is naturally not there. How to make it so that all resources are loaded through the main domain, for example: www.site.com/assets/hash/style.css

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Ivan, 2014-05-02
@go3l337

yiiframework.ru/doc/cookbook/ru/core.assets
Rewrite the CLinkPager::registerCssFile method, adding the required subdomain to the file path.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question