I'm trying to use nForum 1.5 in a multi-site environment but can't get it to work. This is the steps to reproduce it:
Setup nForum inside my multi-site environment (every site has a different hostname setting)
Assign special hostname to nForum (forum.mysite.com) and create some test categories to see everything works!
Now move the forum node to one of my existing sites (intranet.mysite.com) and removing the forum hostname)
Navigating to the forum works but when clicking on a category I get an exception.
After debugging I found that the ReturnRootForumId method throws a null reference. I don't know Examine enough to figure out why / debug it can't find any root forum id here so any help would be appreciated.
Return ReturnRootForumId uses examine to find the first instance of the 'Forum' node, I haven't tested it in a multi-site environment but.. The error indicates it cannot find the 'Forum' node in the index.
Things to try:
Save and publish the Forum node and then republish entire site to rebuild XML - If that doesn't work then...
Delete the index and let it rebuild (App_Data\TEMP\ExamineIndexes) and delete the folder called nForumEntryIndexSet then go into the umbraco admin and again save and publish the forum node and republish entire site.
Tried both your suggestions without success. Actually it worked once, when I touched the web.config, but then it went back to the error:
Error creating usercontrol (usercontrols/nForum/ForumMainList.ascx) Object reference not set to an instance of an object. at nForum.BusinessLogic.Data.ForumFactory.ReturnRootForumId() in D:\Websites\nForum\nForum.BusinessLogic\Data\ForumFactory.cs:line 50 at nForum.BusinessLogic.Data.ForumFactory..ctor() in D:\Websites\nForum\nForum.BusinessLogic\Data\ForumFactory.cs:line 36 at nForum.BusinessLogic.BaseForumUsercontrol..ctor() in D:\Websites\nForum\nForum.BusinessLogic\BaseForumUsercontrol.cs:line 26 at nForum.usercontrols.nForum.ForumMainList..ctor() at ASP.usercontrols_nforum_forummainlist_ascx..ctor() at __ASP.FastObjectFactory_app_web_forummainlist_ascx_15a5d03a_u9eqwu9i.Create_ASP_usercontrols_nforum_forummainlist_ascx() at System.Web.Compilation.BuildResultCompiledType.CreateInstance() at System.Web.UI.TemplateControl.LoadControl(IWebObjectFactory objectFactory, VirtualPath virtualPath, Type t, Object[] parameters) at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath) at umbraco.macro.loadUserControl(String fileName, MacroModel model, Hashtable pageElements)
If you index has rebuilt, then you'll need to open the index up using luke to make sure the 'Forum' document is in there (Open luke and point it at the nforumindex folder I mentioned above, it will then show you all the indexed documents (nodes) and properties)
Its obviously an issue with the multi-site environment, what exactly I'm not sure as I have no tested or used nForum in that environment - Its only been used in a single site Umbraco install as you can see from the video.
Maybe screen shot your backend tree and let me see the structure too. Just to double check, you haven't installed this over the top of an existing nForum version?
using in multi-site environment
I'm trying to use nForum 1.5 in a multi-site environment but can't get it to work. This is the steps to reproduce it:
Return ReturnRootForumId uses examine to find the first instance of the 'Forum' node, I haven't tested it in a multi-site environment but.. The error indicates it cannot find the 'Forum' node in the index.
Things to try:
Tried both your suggestions without success. Actually it worked once, when I touched the web.config, but then it went back to the error:
Error creating usercontrol (usercontrols/nForum/ForumMainList.ascx)
Object reference not set to an instance of an object.
at nForum.BusinessLogic.Data.ForumFactory.ReturnRootForumId() in D:\Websites\nForum\nForum.BusinessLogic\Data\ForumFactory.cs:line 50
at nForum.BusinessLogic.Data.ForumFactory..ctor() in D:\Websites\nForum\nForum.BusinessLogic\Data\ForumFactory.cs:line 36
at nForum.BusinessLogic.BaseForumUsercontrol..ctor() in D:\Websites\nForum\nForum.BusinessLogic\BaseForumUsercontrol.cs:line 26
at nForum.usercontrols.nForum.ForumMainList..ctor()
at ASP.usercontrols_nforum_forummainlist_ascx..ctor()
at __ASP.FastObjectFactory_app_web_forummainlist_ascx_15a5d03a_u9eqwu9i.Create_ASP_usercontrols_nforum_forummainlist_ascx()
at System.Web.Compilation.BuildResultCompiledType.CreateInstance()
at System.Web.UI.TemplateControl.LoadControl(IWebObjectFactory objectFactory, VirtualPath virtualPath, Type t, Object[] parameters)
at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath)
at umbraco.macro.loadUserControl(String fileName, MacroModel model, Hashtable pageElements)
Can somebody help me on how to debug this examine part? Would be really great if I could get this project to work!
If you index has rebuilt, then you'll need to open the index up using luke to make sure the 'Forum' document is in there (Open luke and point it at the nforumindex folder I mentioned above, it will then show you all the indexed documents (nodes) and properties)
http://www.getopt.org/luke/
Its obviously an issue with the multi-site environment, what exactly I'm not sure as I have no tested or used nForum in that environment - Its only been used in a single site Umbraco install as you can see from the video.
Maybe screen shot your backend tree and let me see the structure too. Just to double check, you haven't installed this over the top of an existing nForum version?
Figured it out! I had my forum inside a role-based protected member area. Had to change ExamineSettings.config to allow indexing of protected pages.
is working on a reply...