0
votes

I have created angular4 application and everything is working fine for me. . When I naviagte to url http://localhost:4200/#/dashboard/forms it redirects to particular components. But when I upload that angular application to cpanel and then tried to view that component using url http://example.com/#/dashboard/forms I am getting following error

Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator to inform them of the time this error occurred, and the actions you performed just before this error. More information about this error may be available in the server error log. Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

Is this error related to angular routing or cpanel issues? Any trick to fix this error?

1
Internal Server error always requires to look up the error details in your server logs.Uwe Keim

1 Answers

0
votes

This seems like an error with how the .js file is being served by the cPanel server.

Try to directly load the .js file from your browser

You need to see if you have a .htaccess file / rule that might be causing this as well - usualy .js files do not cause Internal Server Errors - this seems like an issue of how the file is (trying to) being served over HTTP