UrlManager to be case insensitive

Hi,

My site works well for the following link

/site/login.html

but gives 404 error on

/site/Login.html

The urlManager configuration I used is




        'urlManager'=>[

	        'enablePrettyUrl' => true,

	        'class' => 'yii\web\UrlManager',

			'showScriptName'=>false,

			'suffix'=>'.html',

			'rules'=>[

				'<controller>/<action>'=>'<controller>/<action>',

			],

		],




Is there any way the action names can work in case insensitive way? This is for a site built in Yii1 to be changed to Yii2. The old urls in Yii1 worked (eg: /site/Login.html), whereas in Yii2 with the configuration above, it is not working. The old indexed pages in search engines return 404 error.

Request your suggestions.

Hi hrnair,

look at this http://www.yiiframew…ing-pretty-urls this can help you.