Umbraco - No template exists to render the document - umbraco

I want to customize this error:
Page not found
No template exists to render the document at url 'someurl'.
This page is intentionally left ugly ;-)
I did edited umbracosettings.config :
<errors>
<error404>4568</error404>
</errors>
But for some reason the custom 404 works with some pages and doesn't work with others.

Are you sure the visited page HAS a template in the "properties" tab?
Same question for the page with ID 4568: has it a template in the properties tab?

Related

Static changes by saving of web page as "web page complete"

I save a web site using Firefox 33.0 as "Web Page, Complete".
The problem is, the html tree of the main html file is changed statically.
Before saving there was something like that:
Stuff before
<form name="test1>
inner stuff
</form>
Stuff after
After saving it looks follow:
Stuff before
<form name="test1"></form>
inner stuff
Stuff after
I tried Google Chrome and IE. The same thing.
If I save it as "Web Page, HTML Page only", the html tree is saved properly.
What issue could it be?
Thank you in advance.
The "Save as" > "Web Page, Complete" feature, does not save invalid html. The invalid html is modified on save so that it becomes valid.
I don't know what your [inner stuff] is, so I don't know how it is offending, but you can try this for instance with placing a block level element inside an inline element.
<span><div>Hello</div><span>
becomes
<span><span><div>Hello</div>
while
<div><div>Hello</div></div>
stays the same.
In this example the offending elements are pushed outside the container, to make the markup valid.

DevExpress Menu linked to a siteMap

I have a MVC4 project with a sitemap and a devexpress menu item on my _Layout page.
I have a section in my siteMap for InwardsGoods and an index page where the user can QueryDeliveries. The QueryDeliveries is the same page as the InwardsGoods home(Index) page.
<siteMapNode url="InwardsGoods/Index" title="Stock and Deliveries" description="">
<siteMapNode url="InwardsGoods/Index" title="Query Deliveries" description=""/>
</siteMapNode>
When I try to run this it complains about "ConfigurationErrorsException was unhandled by user code" Then "The site map file is invalid"
What I dont understand is when I run the siteMap without the url it runs the menu fine, obviously the link to Query Deliveries wont go anywhere though.
<siteMapNode url="InwardsGoods/Index" title="Stock and Deliveries" description="">
<siteMapNode url="" title="Query Deliveries" description=""/>
</siteMapNode>
How can I edit the sitemap to allow for both siteMapNodes to work?
You can't duplicate the url "InwardsGoods/Index" in multiple site map notes. Change it to "InwardsGoods/Queries" or something in the nested link in the site map.
I managed to get around this by changing the url to InwardsGoods/Queries and in the controller add an action result

How can I remove body from a Page in OrchardCMS?

I currently have 2 page types in my Orchard CMS setup. One is for the front page, one for a detail page. On the front page, I have removed the body from being displayed, so that it just shows 2 HTML widgets.
Is there a way so that when someone edits this page, they don't get a body section?
A placement file might also do the trick: placement also works for the admin ui... That could enable you to make it show or not without requiring two different content types.
You can remove the Body Part from the page content type you use for the front page. This way people who edit this page won't see the editor for body content and the body won't be rendered at all.
HTH

Can I show an erb template in facebook page tab?

I am trying to display an erb template inside a facebook page tab. I am successful in doing so using wordpress, but with rails I am getting this error.
FBML Error: illegal tag "body" under "fb:tab-position"
The output of wordpress and rails are exactly similar. They are generating the same html. While in case of wordpress the contents are getting displayed in tabs, in case of rails it throws an error.
Has anyone successfully implemented a facebook app with page tabs using rails.
Is your template being rendered with a layout? Usually the layout would have head and body tags, which you don't want in your facebook content as it's in the context of a page (facebook) that already defines the head and body. To render a page without layout pass the :layout => false option to your render call.
You are most likely getting an error and the body tag is getting in there from the 500.html or the 404.html.
I tried a million things and I found that I had an invalid authenticity token. To see if this is your issue try:
skip_before_filter :verify_authenticity_token
In your controller that is rendering the view.
As the error message says, in a tab you can't have a 'body' tag. Are you 100% sure the Rails output doesn't somehow have it?
Basically you have to supply Facebook a stripped down HTML as they have their own 'head' and 'body' tags.

The name html doesn't exist in the current context on MVC View Page

HI I have a view that is created from the Controllder Method.
Now I am writing the HTML View Code on this Page.
Somehow I am not getting any html controls on this page.
When i type the below line, it says "The name html doesn't exist in the current context"
Ex: <%= Html.TextBox
Any Clue why i am not getting html tags.
Appreciate your response.
Are you missing your Inherits attribute in your Page declaration at the top of the view?
It should look like this (if it is strongly-typed):
Inherits="System.Web.Mvc.ViewPage<MyNamespace.Models.MyViewModel>"
or like this (if it is not strongly-typed):
Inherits="System.Web.Mvc.ViewPage"
I find that if I remove this declaration from my view, the Html object will no longer intellisense.

Resources