ASP.NET Web Pages cshtml files not recompiling on server

John Avis by | August 18, 2020 | ASP.NET Web Pages

I have an old website written in ASP.NET v4.x Web Pages v1.0.0.0 and when I upload changes to my shared hosting provider some cshtml files update fine and I can see the changes, but some do not.
I have an old website written in ASP.NET v4.x Web Pages v1.0.0.0 (not Web Forms or MVC).

When I upload changes to my shared hosting provider some cshtml files update fine and I can see the changes, but some do not. They seem to be stuck and won't recompile on the server.

The problem files are suspiciously all in the same folder.

If I delete the updated file I get a 404 error as expected but even when I reupload the file I see the old version in my browser.

I download the file and checked that it was the right version, which it is.

I also tried renaming the folder in case it was a reserve folder name, but no change.

I have tried recycling application pool, restarting site and changing web.config to force it to update but nothing works. I also tried various options for fcnMode in web.config but no change. It is shared hosting so I can't restart the server or IIS.

The only thing that worked for me was moving the files to a different existing folder. That seemed to work but I don't know why.

Related Posts

Disabling request validation in ASP.NET Web Pages

by John Avis | November 27, 2019

How to avoid A potentially dangerous Request.Form value was detected from the client errors when developing in ASP.NET Web Pages.


Using WebMatrix.Data in ASP.NET Web Forms

by John Avis | July 17, 2013

ASP.NET Web Pages has a simple to use Namespace that help you open, query and send commands to a database, and to work with rows that are returned by SQL queries.


Installing ASP.NET Web Pages Helpers in Visual Web Developer 2010

by John Avis | May 21, 2011

Comments

There are no comments yet. Be the first to leave a comment!

Leave a Comment

Tags

About

...random postings about web development and programming, Internet, computers and electronics topics.

I recommend ASPnix for web hosting and Crazy Domains for domain registration.

Subscribe

Get the latest posts delivered to your inbox.