Umbraco 7 upgrade blank screen: unexpected token > - umbraco

We are attempting to upgrade an umbraco 7.2.8 site to umbraco 7.5.8. When I load the backoffice to get a hold of the upgrade wizard, I am presented with a blank screen. When I inspect element, I see this: Uncaught SyntaxError: Unexpected token <. The reference to the error is: /umbraco/Application?umb__rnd=ffffffffb6d9a809.
Has anyone seen this error during an upgrade?

I figured it out. I navigated to the Sources tab of the chrome dev tools and found the Application?umb__rnd. I attached a screenshot of what I saw. It looks like there is some problem with ASP.NET Tracing set up on this site. I went to the web.config and found the configuration and set enabled=false. This solved my problem, and I was able to continue with the upgrade. I also found out that reenabling trace will break the backoffice even after the upgrade is complete. I will look into this more to find out if this is a problem specific to this umbraco site or if it is some sort of compatibility problem with ASP.NET Trace and Umbraco 7.5.8.
This was the problem:
<system.web>
<trace enabled="true" requestLimit="10" pageOutput="true" traceMode="SortByTime" localOnly="false" />
This is the clue I found in the chrome inspector:

Related

How to Show Complex Error Page on Server

I have written an ASP.NET MVC App that is running on a Google Compute Engine. The app is getting a 500 Error on the main Index page that does not occur when running on my local machine.
I am trying to get the complex error page to show from the server, as it is much easier to view them on the web page for hotfixing issues than to delve into the Google Cloud Console to retrieve them. I do not want custom errors, just the same amount of depth that gets shown when running on my local machine.
I have tried:
Removing the existing HTTP Global Filter
Adding <customErrors
mode="Off"/><compilation debug="true"/> to my System.Web in
Web.config
Adding <httpErrors errorMode="Detailed" /><asp
scriptErrorSentToBrowser="true"/> to my System.WebServer in
Web.config
Publishing as debug
Ideas? I'm sure theres a publish setting I'm missing somewhere.
Adding a constructor to the page controller finally provided the detailed error log. If you have taken all of the steps above to get the log, and it still has yet to show, ensure there are constructors for all view controllers involved. Even if the constructor is blank.
I still need to delve into my particular crash issue, but at least I can get an idea where to start.

Getting Error 404 after deploying MVC on IIS due to query string

I just deployed an MVC app on my IIS and seem to be having issues with any URL with query string.
If I open "http://serverip/app/controller/action", it works fine but if I open "http://serverip/app/controller/action/id", I get error 404.
I don't know what to do. Some links I visited did not help, perhaps, I don't understand the instructions to resolving the issue.
Please help.
This is quite often caused by the following missing from the web.config:
<system.webserver>
<modules runAllManagedModulesForAllRequests="true"/>
I have experience throwing an exception in Controller will lead to occur this sort of error. returning 404 Not found error to the front end. So make sure that after deploy into any other environment, if no any configuration or integration issue with API server which will lead to happen exception

Getting "A default document is not configured " error when deploying ASP.NET MVC application on IIS 7.5

Developing an ASp.NET MVC 5 application. Runs without an issue on the development machine (Windows 7 x86). When I tried to deploy it on IIS 7.5 (Win Server 2008 R2 64 bit) I got 3 errors:
Unrecognized attribute 'targetFramework'. Note that attribute names are case-sensitive.
I fixed this issue by removing targetFramework="4.5" from
<compilation debug="true" targetFramework="4.5">
The tag contains an invalid value for the 'culture' attribute.
I don't know why but compliant was about the following entry:
<globalization enableClientBasedCulture="true" culture="az-Latn" uiCulture="az-Latn" />
After removing culture="az-Latn" uiCulture="az-Latn" this problem also got solved. But I don't think this is a proper way of solving that, so it'd be good to know the right solution.
Now the third error is the one that's taken all my day. After solving the above two problems now I get the error in the image:
The best solution that seems to work for almost everybody is to add the following entry:
<modules runAllManagedModulesForAllRequests="true" />
But I already have it in the config file. IIS was missing URLRewrite module so I installed it manually.(Don't know if this has anything to do with it though). Didn't help. Enabled 32 bit Applications. Didn't help. What else should I try?
There are two possible solutions
Make sure the application pool that is running your site is set to version 4. It's likely defaulted to v2 which will give you all the errors you mentioned in the question.
Re-register your framework with this command:
C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis -i
I'd also revert those changes you have made (e.g. put the targetFramework attribute back in)

Recaptcha giving 404 error on Validate in SSL site

In my ASP.NET MVC 4 project, I am using the Microsoft.Web.Helpers (from the NuGet package) and my code is a very basic implementation of ReCaptcha. In my view I have:
#ReCaptcha.GetHtml(theme: "clean")
In my controller I have:
Microsoft.Web.Helpers.ReCaptcha.Validate();
The complexity comes with the SSL implementation we are using.
I have added the appropriate settings to my web.config:
<system.net>
<defaultProxy>
<proxy proxyaddress="http://***proxy script settings**"
autoDetect="False"
usesystemdefault="False"
bypassonlocal="True" />
</defaultProxy>
</system.net>
There seems like there is nothing further I can do in terms of config, but I am getting the error message
The remote server returned an error: (404) Not Found
when I hit the recaptcha validate method on the form post method in my controller.
Ive found a number of other answers on here but they all seem to suggest that you change the url, or upgrade. As Im using a NuGet package I would have thought I was using the latest version. Any ideas or links with more information greatly appreciated. Ive already done quite a bit of looking both on this site and google
edit:
I have found that earlier versions of firefox have trouble actually rendering the recapture box given our network conditions, but the latest one is fine. As the validation is done on the controller though, I suppose there is no issue here.
After much pulling of hair and general confusion, I discovered that the problem was that the POST (but not the GET) to the google API was being blocked by our corporate firewall. I had previously discounted this, because I could navigate to the service that recaptcha uses (http://www.google.com/recaptcha/api/verify).
I found this by constructing an HTML page of the requisite parts for the post and submitting it in a browser. The corporate "This page is blocked" appeared - however in code the error that is returned is a 404. The error is somewhat misleading, but this is bizarre behavior from our infrastructure department.

ASP.NET MVC Unknown server tag error

I was wondering why could I have not caught this issue in local testing? I am using a Content Panel user control in all my user controls. In one of the user control I missed the register tag for Content Panel UC. While testing locally all things were working fine . Suddenly on our QA box I got a critical issue. Application was throwing Unknown server tag 'cc1:ContentPanel' in the Landing page.
Can anyone explain why it was not caught locally?
Most likely there is a mismatch in your web.config files.
Use a diff program to compare the web.config on QA against the web.config on your box.
I bet you'll find the problem there...

Resources