Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ASP.NET MVC Missing Default Action only for one controller

I don't know what happened to my website. From today the default action "Index" in only one controller doesn't work anymore. If I call http://website.com/Valuation i get 403 error page because the webserver doesn't route my request and try to browse the folder. If I write http://website.com/Valuation/Index everything works. I search in all the code but i can't find the problem, everything seems fine like other controllers.

How can i find the problem? Do you know if there are a known issue that cause that problem or you know if there is a trace\log\debugger of routing requests?

Thanks

Mic

like image 913
Michele Massari Avatar asked Jul 24 '26 14:07

Michele Massari


1 Answers

Most probably the issue is you have a folder by name Valuation in your website root. Thats why the valuation index action is not working. Instead of routing to the Controller Action the url http://website.com/Valuation is routing to the Folder Valuation.

Delete this folder Valuation from your root or rename it then this url http://website.com/Valuation will work.

Also check if the ValuationController has the public ActionResult Index() ([HttpGet] method.

like image 163
Rolwin Crasta Avatar answered Jul 26 '26 02:07

Rolwin Crasta



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!