Level 1
Can i remove the trailin / when I redirect to the public folder
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hello Everyone,
I am trying to deploy my Laravel project in a subdirectory. I have got an issue with the root route. I have to put / with my domain path to access the root domain but my other routes work fine.
my folder structure
public_html/public/ //my all public files
Now my link for root access is below.
http://mysite/public //give me errors
I have to put '/' in last
http://mysite/public/ //now it work
other routes
http://mysite/public/my-page
http://mysite/public/my-other-page //work fine
I have not change anything in the .htaccess file.
Please help me to solve this.
Please or to participate in this conversation.