RewriteCond %{PATH_INFO} ^/foo/(baz|symfony)$ RewriteRule .* app.php [QSA,L,E=_ROUTING__route:foo,E=_ROUTING_bar:%1,E=_ROUTING_def:test] RewriteCond %{REQUEST_METHOD} =GET [OR] RewriteCond %{REQUEST_METHOD} =HEAD RewriteCond %{PATH_INFO} ^/bar/([^/\.]+?)$ RewriteRule .* app.php [QSA,L,E=_ROUTING__route:bar,E=_ROUTING_foo:%1]