AnSilva Posted June 19, 2022 Share Posted June 19, 2022 Hi! I need help creating pages. I'm used to WordPress, where everything happens automatically, but here I don't understand. I need to create pages and set up their URLs. I was able to create pages, but when creating them they became accessible only through the URL: https://domain/test_page.php Why does it happen? After searching a lot I think it is necessary to create a rule so that the URL "https://domain/test_page/" displays the contents of the file "https://domain/test_page.php" Okay, so far I understand. My server is NGINX. The problem is that when set up the “rewrite” rules as follows: rewrite ^/test_page/$ /test_page.php last; The page only opens if we type the address with the last slash, that is: "https://domain/test_page/" but if I type without the last slash, like this: "https://domain/test_page", it shows error 404, the page is not redirected. Is this really the page creation process? Do I always need to change these rules in NGINX? How can I simplify adding pages? Also, after installing KVS on my NGINX server, all pages only work if I type the last slash in the URL: "/test_page/". If I type without the last slash, ie "/test_page", it shows a 404 error. Is that right??? In all pages? Quote Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.