We are currently migrating our Umbraco sites to a new web host. 99% of everything is in good shape, but we do have one page that is misbehaving on the new host. Basically, there is a view associated with a macro. The view only loads a semicolon on the web page. We have verified that everything (at least everything we can think of) is identical between these servers.
If I remove the ; from the Html.Action, the view returns nothing at all. If I add in any other text, like <div>Help me. I am losing my mind.</div>, I see that text; however, the InitWarrantyForm method in the WarrantySurface controller is never called.
Can anyone think of any idea why this is happening?
Without knowing what the InitWarrantyForm action is for, it's difficult to say - it looks to not be returning any sort of output or return value (which is why you only get the semi colon - it's being rendered as text as it's not needed for the Razor script.
When you say the controller isn't called, have you checked by stepping through with a debugger? Or try returning a hardcoded value?
I had tried stepping through InitWarrantyForm and returning a hard-coded value, but I couldn't find a problem. My coworker, however, found the issue. It was related to a missing XML file of some data that the view needed. The failure was very silent: no errors, no exceptions, just emptiness with no explanation.
MacroPartial view only shows a semicolon
Good afternoon!
We are currently migrating our Umbraco sites to a new web host. 99% of everything is in good shape, but we do have one page that is misbehaving on the new host. Basically, there is a view associated with a macro. The view only loads a semicolon on the web page. We have verified that everything (at least everything we can think of) is identical between these servers.
Here is the code of the view:
If I remove the
;
from theHtml.Action
, the view returns nothing at all. If I add in any other text, like<div>Help me. I am losing my mind.</div>
, I see that text; however, theInitWarrantyForm
method in theWarrantySurface
controller is never called.Can anyone think of any idea why this is happening?
Thanks!
Jeremy
Without knowing what the InitWarrantyForm action is for, it's difficult to say - it looks to not be returning any sort of output or return value (which is why you only get the semi colon - it's being rendered as text as it's not needed for the Razor script.
When you say the controller isn't called, have you checked by stepping through with a debugger? Or try returning a hardcoded value?
Matthew,
I had tried stepping through InitWarrantyForm and returning a hard-coded value, but I couldn't find a problem. My coworker, however, found the issue. It was related to a missing XML file of some data that the view needed. The failure was very silent: no errors, no exceptions, just emptiness with no explanation.
Sounds philosophical.
At any rate, we got it sorted out.
Thanks!
Jeremy
is working on a reply...