I need to require a domain name in my symfony routing, my route looks like the following:
domain_example:
url: /routing/example/:domain_name
param: { module: myModule, action: index, sf_format: json }
requirements: { domain_name: '/^[a-z0-9]+([\-\.]{1}[a-z0-9]+)*\.[a-z]{2,5}$/' }
I have also tried:
requirements: { domain_name: '[/^[a-z0-9]+([\-\.]{1}[a-z0-9]+)*\.[a-z]{2,5}$/]' }
If I call my route like so: mydomain.com/routing/example/otherdomain.com
- I just get the module/action does not exist exception.