Question

Subdirectories direct to parent directory in Nodejs App

Posted December 27, 2021 104 views
Node.js

Hello Digitalocean Community
I have this weird occurrence that happens to me on Digitalocean but not on localhost.
So Basically this is my website dashboard: https://elsafaplastelec.com/dashboard
and I want to access https://elsafaplastelec.com/dashboard/products but it directs me to https://elsafaplastelec.com/dashboard
Although in Localhost, It works correctly
Is there any clue regarding this behaviour?
The website is based on nodejs

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
Submit an Answer
1 answer

Hey there!

It may be necessary to specify some additional routes to your products if they are part of the dashboard. It does currently look like you have a 302 redirect to the dashboard page when hitting that dashboard/products page. If the dashboard you are running has a built in redirect to the login page, you may need to remove the 302. If it doesn’t you can try adding additional routes in your app’s routes section in the UI to get those correct routes.

App Platform Routes

Hope it helps!
Nate