Hi, Thank you for your answers.
So I tried on an empty wordpress with only the above routine, but it does not work like this. if the name of the page is different from the-blog then yes it works. But if the page is called the-blog then error 404
With page name toto (local host)
https://www.test.fr/the-blog/2014/10/04/demo-post-38/
With page name the-blog (local host)
https://www.test.fr/2/ (local host) error 404