Upgrading to version 1.1.17+ broke my routes.
trigger202 opened this issue · 1 comments
What steps will reproduce the problem?
I am having issues with broken links after upgrading from Yii 1.1.13 to 1.1.28 this because of the change made in Yii .1.17 regarding `parsingOnly' attribute in UrlRule.
I noticed any route that has optional parameter fails 'pattern' => 'agent/<action:(start)>(/<reference:([A-Za-z0-9\-]+)>)?'
which should match /agent/start/1F21-2K1I-INS
What is the recommended solution for this?
I have many routes and hesitant about breaking my application.
one thing that worked for me so far is to separate into mutliple rules.
- one with no parameter
- another route with required parameter.
What is the expected result?
'pattern' => 'agent/<action:(start)>(/<reference:([A-Za-z0-9\-]+)>)?'
which should match /agent/start/1F21-2K1I-INS
What do you get instead?
I get 404 page.
Additional info
Q | A |
---|---|
Yii version | 1.1.28? |
PHP version | 7.1? |
Operating system | MacOs (sonoma) |
@trigger202 Sorry, but this is not the right place to ask for support in this case. The release that maybe broke your application is 6+ years old and Yii is only receiving security and compatibility fixes at this time. If there is a demonstratable bug in the framework we may look at it, but it could be in your application code or config as well.