Closed refringe closed 5 years ago
I have a route:
$route['cms/file/crop/(holding|image)/(thumb|full)/([a-zA-Z0-9]{32})'] = function ($library, $crop_type, $name_hash) { return 'cms/file/crop_'.$library.'/'.$crop_type.'/'.$name_hash; };
Which causes the following error:
Severity: Warning --> preg_match(): Compilation failed: missing ) at offset 61 /srv/www/site.ca/private/codeigniter3/system/core/Router.php 399
After putting a debug output on line 399:
log_message('debug', "Router RegEx: #^'.$key.'$#'");
It writes the following to the debug log:
Router RegEx: #^'.cms/file/crop/(holding|image)/(thumb|full)/([a-zA-Z0-9]{32}.'$#'
Note the missing ) on the right.
)
Currently using (:any) as a workaround, but the former should work fine as well, no?
(:any)
Can't reproduce.
I have a route:
Which causes the following error:
Severity: Warning --> preg_match(): Compilation failed: missing ) at offset 61 /srv/www/site.ca/private/codeigniter3/system/core/Router.php 399
After putting a debug output on line 399:
log_message('debug', "Router RegEx: #^'.$key.'$#'");
It writes the following to the debug log:
Router RegEx: #^'.cms/file/crop/(holding|image)/(thumb|full)/([a-zA-Z0-9]{32}.'$#'
Note the missing
)
on the right.Currently using
(:any)
as a workaround, but the former should work fine as well, no?