Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

shariff's avatar
Level 50

Subfolder name is getting concatenated in server

Hi

I have laravel 9 project and uploaded to shared hosting. After uploading when I call the url automatically the url is getting concatinated.

For example

i'm calling

xxxxx_.com/app/public/

it is coming like this

xxxxx_.com/app/public/app/public

Thanks

0 likes
4 replies
Snapey's avatar

Set the document root for your application correctly so that your server serves the app's public folder

shariff's avatar
Level 50

@Snapey We cannot do using .htaccess? Already there a wordpress website in document root. Laravel app is uploaded to folder

Snapey's avatar
Snapey
Best Answer
Level 122

@shariff you run a big risk of exposing your secret credentials, and also will get problems like this

better to use a subdomain or second host account

1 like
shariff's avatar
Level 50

@Snapey Okay thanks for the response. I will create a subdomain and host. Thank you so much

Please or to participate in this conversation.