How, in Yii, to get the current page\'s URL. For example:
http://www.yoursite.com/your_yii_application/?lg=pl&id=15
but excluding the
In Yii2 you can do:
use yii\helpers\Url; $withoutLg = Url::current(['lg'=>null], true);
More info: https://www.yiiframework.com/doc/api/2.0/yii-helpers-baseurl#current%28%29-detail