How to configure .htaccess for history API?

Such cases.

Using the history API, I will have to be generated, for example, flowers.
Ie when you click on a flower on the main (/) the link will look like this: /flowers/rose
But what to do with .htaccess? Because when you go to that link, the server will try to give the page that does not exist.

In General, it is necessary that all /flowers/***** was redirecting to the main, but the address remained

In this case, to configure .htaccess?
July 2nd 19 at 18:04
1 answer
July 2nd 19 at 18:06
RewriteEngine On
RewriteRule ^(.*)$ index.php [L,QSA]
and here the server will understand that it is necessary to redirect it all /flowers/**** pages? - Durward_Osinski commented on July 2nd 19 at 18:09
if you only need only /flowers/?

Create a folder flowers in her file .htaccess with the contents
RewriteEngine On
RewriteRule ^(.*)$ /index.php [L,QSA] - Alfred.Padberg86 commented on July 2nd 19 at 18:12

Find more questions by tags FrontendhtaccessJavaScript