Url Rewriter - Advanced rule - Cookie not existing


We are trying to implement a redirection, via an advanced rule, which relies on a cookie value.
This is working fine, however, we also need the same redirection to happen when the mentioned cookie is not existing yet (first time visit). Is there any way to implement this in the Url rewriter?

Edit: I have added an additional ‘normal’ rule doing the same redirection, without the cookie condition.
At first glance it seems to be working, but can we be sure that this will always work?
Is there any possibility to prioritize redirection rules?


Redirect rules are processed in the order they are found. Which is basically the order you see in the cms, top to bottom. When a rule is matched processing stops, unless you have indicated it should continue (selected process other rules). See also the documentation, especially the following

Which rules and conditions have been configured and in what order they will be processed can be seen on the status page, which is accessible locally at /rewrite-status. See also the corresponding configuration in the site module’s web.xml.

1 Like