I am having the following rewrite rule :

add_action( 'init', 'custom_rewrite_rules' );
function custom_rewrite_rules() {
    add_rewrite_rule('formation(/([^/]+))?(/([^/]+))?/?','index.php?pagename=formation&formation_slug=$matches[2]&formation_id=$matches[4]','top');
    add_rewrite_tag('%formation_slug%','([^&]+)');
    add_rewrite_tag('%formation_id%','([^&]+)');
}

This works fine on my Apache server, and not on my client’s IIS.
I flushed the rewrite rules and the Monkeyman Rewrite Analyzer plugin tells me the redirection should work as planned.

Any suggestion of what I am missing?

Thanks a lot in advance for your help

Read more here: WordPress add_rewrite_rule working on Apache, not on IIS


Solution:

If you know the solution of this issue, please leave us a reply in Comment section, to update the question.

Related Wordpress search:

, , , ,

Wordpress related questions and answers: