I'm working on a larvel project where everything is fine when I enter the url(domain) without /index.php. Suppose my url is https://example.com. When I go to this url, everything works perfectly. But if I add /index.php at the last like https://example.com/index.php, my resources(images, videos) are not loading because of path mismatch. So far I figure out I need to redirect that https://example.com/index.php to https://example.com by defining rules on .htaccess file.
So how can I write the rules correctly so that it redirects to https://example.com when I enter https://example.com/index.php ?
Update: In development my project is running on http://localhost:3000/Example. In this case I need to redirect this http://localhost:3000/Example/index.php to http://localhost:3000/Example.