Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Yannick Smits 321 posts 718 karma points
    Jan 16, 2012 @ 20:35
    Yannick Smits
    0

    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:

     

    1. Setup nForum inside my multi-site environment (every site has a different hostname setting)
    2. Assign special hostname to nForum (forum.mysite.com) and create some test categories to see everything works!
    3. Now move the forum node to one of my existing sites (intranet.mysite.com) and removing the forum hostname)
    4. 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.

     

  • Lee 1130 posts 3088 karma points
    Jan 16, 2012 @ 21:09
    Lee
    1

    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.
  • Yannick Smits 321 posts 718 karma points
    Jan 16, 2012 @ 22:04
    Yannick Smits
    0

    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)

  • Yannick Smits 321 posts 718 karma points
    Jan 17, 2012 @ 17:00
    Yannick Smits
    0

    Can somebody help me on how to debug this examine part? Would be really great if I could get this project to work!

  • Lee 1130 posts 3088 karma points
    Jan 17, 2012 @ 19:37
    Lee
    1

    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?

  • Yannick Smits 321 posts 718 karma points
    Jan 21, 2012 @ 21:31
    Yannick Smits
    1

    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.

Please Sign in or register to post replies

Write your reply to:

Draft