Deployment of OpenForum with existing project

Mar 14, 2010 at 11:53 PM

Hi Eric,

I'd love to contribute to the project, pending you'd have no objections to it.

My first set of issues that I have which I'd love to discuss with you are the ideas that there is no way of "deploying" the database scripts to the database as changes are needed, and I see your OpenForum.Views.Compiled appears to need a special project type in order to load properly.  Can you shed some decent light on these two topics so that I can work on adding a few items to your starter system?

Mar 16, 2010 at 3:07 PM

Hey Duncan,

You can download the web deployment project at That should get you compiling.

There currently is a sql script that can be run in order to deploy to a database. This could be better, but it should do the job for now. What would you like to see here?

Mar 16, 2010 at 7:02 PM

I am also having a problem building the project even after installing the web deployment project. I get a variety of errors during compliation. The errors start with a webconfig issue, which I was able to resolve by removing forms authentication. Then there were reference errors to the OpenForum.dll in the "Views" project, however there isn't a reference section there to add one.

Any help in getting this to compile would be greatly appreciated as I need to add a captcha because my site is getting bombarded with spam.


Mar 18, 2010 at 3:14 PM

Heh... i do need to get a better, more business professional, handle for these forums :)

Anyway, my hangup is not in getting your code to run, but the deployment and maintainability of the code if it is put into a production environment.  It took me about 2 years to learn about this feat, as I had never faced it before.. the systems that i worked on were of the type that you would send a sql script to your manager, and they'd deploy it once, and you were done.  Now that I'm getting into wrapperware software development, I'm understanding the reasonings for teams of "installation development specialists" and such.

What I'm getting at is if there is a way of providing versioning on the database?  Something as simple as an xmldocument where you would have

<upgrade id="1">
<modification id="1">create table..</modification>
<modification id="2">drop index.</modification>
<modification id="3">alter table..</modification>

and then a management utility that runs and verifies the database is at the right revision for the codebase running against it.  it makes it much,much easier for contributions where many people have to make database changes to enhance the core structure.


Mar 18, 2010 at 8:20 PM

Help........I am struggling getting the source code to build. I download the files unziped them into C:\OpenForum and from VS2005 I perform a " load web site " and point to that directory. The web site loads fine and all projects show up. When I press "Build" however I get a variety of build errors that I have not been able to resolve.

Can someone please tell me how they were able to get the projects to build? My goal is to be able to update the controllers and views to provide custom features........

-- John

Mar 18, 2010 at 8:37 PM

@duncan16 - I like the idea. If you want to build that out, it would be great. It actually sounds like it could be it's own open source project that could then be used inside OpenForum

Mar 18, 2010 at 8:41 PM

@jtnielsen1 - Can you give me some more detail about the build errors your gettings? I haven't tried building OpenForum with VS2005. I seem to recall that MVC requires at least .Net 3.5.

Mar 18, 2010 at 8:41 PM
Edited Mar 18, 2010 at 8:46 PM

@herbrandson -

I have a hack-ish build of it already :)  Let me see what i need to do in order to get a codeplex site going, and I'll see @ publishing it.

My issue, and I'll fully credit it on there, is that a buddy of mine gave me the technical theory on how they do it for their product (restaurant package built on .Net.)

A hope of mine is to someday get it where I can manage multiple schemas for MsSql/MsSqlCE/MySql/etc.... but that's a pipe dream.


Any good suggestions on a naming of the project?  I have the project called "Schema Script Editor" right now, but would be willing to suggestions...

Also, any preferences on source control between Hg and TFS?

Mar 19, 2010 at 8:07 PM

I tried VS2005 and VS2008 but for this test I'm using V2008

Its odd because it won't open as a "Project" it will only open as a "Website" which for MVC seems strange.

1. I unzip to c:\OpenForum

2. Open as WebSite in VS2008

3. Select Build with the top most solution selected.

Error 1 It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level.  This error can be caused by a virtual directory not being configured as an application in IIS. C:\OpenForum\CustomLook\Web.config 52 

4. Since I don't want the custom files I remove CustomLook, and CustomUsers from the project.

5. Select Build Again and the following error is generated based on the WebConfig in the OpenForum.Views project

Error 4 The type or namespace name 'OpenForum' could not be found (are you missing a using directive or an assembly reference?) C:\OpenForum\OpenForum.Views\Web.config 27 

From here I can't seem to get much further any ideas?

Mar 19, 2010 at 8:12 PM

Does this link help?

Mar 23, 2010 at 6:23 PM

Sorry no luck with that, I actually read that article before but was unable to resolve the issue with it. I guess at this point maybe If I can override the View that creates the Post and Reply to add a client side captcha it'll be enough. There is a video that describes how to override the "Index" view which I tried to mimic in overriding the Post and Reply Views but have not had any luck. I actually want to have the base class view shown as is and then my override view simply add the captcha. I'd hate to loose all the formating that is in there already which is what happens in the Index View example.



Mar 23, 2010 at 7:41 PM

I think a client side captcha might not have the expected result. Bots would easily defeat it by simply posting straight to the server. Are you able to build/run if you use the webserver built into VS instead of using IIS?

Mar 25, 2010 at 7:09 PM

Sorry I was never able to get the project to build, its ashame because I thought I could add some nice features which I need for my site without the massive feature list most other open source forums have. I looked at a product from jitbit, and yetanotherforum which both look promising, and through initial testing was able to build and integrate them into my MVC application. Thanks for your support in trying to help maybe I'll check this out again another time when some of the features I need are available.

You know what is funny is I can't believe how difficult it is to build this project its insane. This should have been a no brainer, I'm clearly doing something wrong, but I have built and written dozens of MVC apps with no problem. Anyway to answer your question yes I am using in in the VS environement I never tried publishing it to IIS becuase I could never get it to build