Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive

Tags:

asp.net

I'm trying to up load my site and I'm getting this error message:

Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.

<compilation debug="true" targetFramework="4.0"> 

The site works fine on my local PC but won't open when I loaded it to my host and tried to view it online.

like image 907
Mike Nacci Avatar asked Sep 23 '11 14:09

Mike Nacci


1 Answers

This typically happens when you have an attribute of targetFramework="4.0" in the web.config but the App Pool is set to run ASP.NET 2.0. The targetFramework attribute is entirely unrecognized by ASP.NET 2.0 - so changing it to 2.0 won't have the desired effect.

Contact Support / Your Administrator and have the AppPool switched to 4.0.

You could also remove the attribute entirely, however if your site was coded with the 4.0 Framework, then I'm sure something else will cause an error as well.

like image 74
vcsjones Avatar answered Oct 12 '22 20:10

vcsjones