Menu Issue

May 9, 2011 at 6:39 PM
Edited May 9, 2011 at 10:32 PM

Has anyone else had problems with custom menu items added to the BE Nav menu?   When I select an aspx page after first visiting a child XML page added through BE I get an error message because the url has an additional level added called /page/ e.g. instead of default2.aspx the browser is looking for /page/default2.aspx.  If I access the aspx page first it finds it as expected.  I tried adding a new folder called page and copied the files across, but this didn't work either, although it works fine run on localhost!  Any suggestion would be appreciated.

 

Steve

May 9, 2011 at 10:31 PM

Also getting this error message:

Object reference not set to an instance of an object.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:

Line 105:                if (doc != null)
Line 106:                {
Line 107:                    XmlDocumentByZone[this.ZoneName] = doc;
Line 108:                }
Line 109:            }


Source File: m:\............\wwwroot\App_Code\Controls\WidgetZone.cs    Line: 107

Coordinator
May 10, 2011 at 7:27 AM

The folder name "page" is a reserved virtual folder used by BE.  It's used for "Page" URLs, like this one for example.

If you create a real folder named "page" and put content in there, BE is probably trying to interpret requests to that folder as Pages.  So it would be better if you chose a different folder name.

May 17, 2011 at 9:37 PM

I'm still really struggling with this issue.  Am I the only one using aspx pages with blogengine?  If I go from xml page to contact then to an aspx page it works ok, but if i go from an xml page to an aspx page it looks for example.aspx in a directory called page which doesn't exist e.g. /page/example.aspx!

Coordinator
May 17, 2011 at 10:42 PM

Hi sjp700, can you clarify what you mean by "go from xml page to aspx page"? As for having "/page/" as part of the path, yes, application uses URL rewrite to generate page which does not exist physically. Just as you won't find .aspx file for every post in your blog, it is generated by app. For example:

http://dotnetblogengine.net/page/extensions.aspx

There is not directory called "page" and no file called "extensions.aspx" on that server.

May 18, 2011 at 7:54 AM
Edited Oct 24, 2011 at 9:36 PM

I think Sjp means   "Stand Alone" pages  to the  "XML Pages"  BE generated pages made within the admin of BE.

 

"XML Pages"    Pages made by BlogEngine uses XML for the content.

"Aspx Page"     [Stand alone page]  Page made by hand or Visual Studio not BlogEngine, content hard coded into page.

 

 

SJP  can you give URL so I can see this?

 

I use "aspx" pages within BlogEngine.


Java Blog

May 26, 2011 at 7:18 PM

Solved problem using Utils.AbsoluteWebRoot in href; see below.  

<a href="<%=Utils.AbsoluteWebRoot + "YourPage.aspx"%>">Events</a>