Custom Section: No umbraco document matches the url
I have had some success added my first custom section to Umbraco 6. My project need a simple Competition engine so this is a good test run of the process of adding custom dashboard pages.
So far I have a new Section icon created and working. When you click it the new Competitions section links are loaded.
When I click for example the Add Competition button, the panel on the right should load an .aspx page called addCompetition.aspx. However I get this.
I can guarentee that the addCompetition.aspx page exists.
(Note the test.html file)
Even if I put that url directly into the browser..
The pipeline takes over your url and assumes it's the url of an Umbraco document. Which makes sense, because the "WebForms" folder is unknown to Umbraco ie it's not one of the reserved paths -- where we know we're not processing an Umbraco document but a normal aspx page. Can you try Rich's suggestion? That should tell the pipeline that "WebForms" is special and _not_ the path to an Umbraco document.
Custom Section: No umbraco document matches the url
I have had some success added my first custom section to Umbraco 6. My project need a simple Competition engine so this is a good test run of the process of adding custom dashboard pages.
So far I have a new Section icon created and working. When you click it the new Competitions section links are loaded.
When I click for example the Add Competition button, the panel on the right should load an .aspx page called addCompetition.aspx. However I get this.
I can guarentee that the addCompetition.aspx page exists.
(Note the test.html file)
Even if I put that url directly into the browser..
http://localhost/WebForms/addCompetition.aspx
it does not work.
I can even guarentee that the path is correct by loading the test.html file. If I put in
http://localhost/WebForms/test.html
... the test.html page is displayed.
Next as test I changed the code to load a UserControl in the right panel instead. A control called addCompetition.ascx
However that resulted in this error..
The request filtering module is configured to deny the file extension.
Is there some Umbraco config file that needs to be set up to allow either of the techniques above to work?
Should I use a webform or a usercontrol on the right of the dashboard?
Another thought I just had is, could it be that Umbraco 6 is looking for an MVC View for the right panel?
WebForm, UserControl, View? I don't care. I just need to know what to build and how to let Umbraco 6 know to accept it.
Hi Brad
I built http://our.umbraco.org/projects/backoffice-extensions/tag-manager using a custom section - this is based on web forms.
The source code is available so feel free to download that.
A snippet of code from the project which relates to your question is below with the id being the id of the tag entry in the database table.
Not sure if this will answer your question but hope it helps.
Cheers, Nigel
Nigel
That code looks identical to the code I have used..
I can see from my screen shot above the path to the page is correct.
localhost/WebForms/addCompetition.aspx
So the issue is not in this Render method.
The path is correct, the aspx page is not found but an HTML file in the same folder is.
I just don't get it.
Hey Brad,
Don't you just need to add to your reserved paths in web.config?
<add key="umbracoReservedPaths" value="~/umbraco,~/webforms/" />
Rich
The pipeline takes over your url and assumes it's the url of an Umbraco document. Which makes sense, because the "WebForms" folder is unknown to Umbraco ie it's not one of the reserved paths -- where we know we're not processing an Umbraco document but a normal aspx page. Can you try Rich's suggestion? That should tell the pipeline that "WebForms" is special and _not_ the path to an Umbraco document.
Give that man a cigar, or a beer, day of bug free coding! :)
That was it. I just had to add the WebForms folder to the umbracoReservedPaths key in appSettings.
Safe to say I would NEVER have worked this out by myself.
Thanks Rich and thanks Stephan for the explaination.
is working on a reply...