This article assumes you have already got the source code for mojoPortal either from svn or from the mojoportal-x-x-x-x-sourcecode.zip file.
Tip: If working with the source code I recommend getting the code with TortoiseSVN. Good work is happening all the time, why get anything less than the latest greatest.
You must have Visual Studio 2005 SP1 or higher.
Setup your database, either MS SQL, MySQL, or PostgreSQL
Open the mojoportal.sln file in VS 2005.
Branch down the references node under the mojoPortal.Business project and make sure it has a reference to the correct data layer for your needs. I usually check it in configured for mojoPortal.Data.MSSQL (Microsoft SQL Server) but you can easily change this. Delete the reference for mojoPortal.Data.MSSQL, then right click the References node and choose Add Reference. In the dialog,click the Projects tab and choose either mojoPortal.Data.pgsql, mojoPortal.Data.MySql and click OK

Open the Web.config file in VS 2005 by browsing to the root of the mojoPortal.Web Project in VS 2005 Solution Explorer.
Edit the database connection string in the Web.config file. Note there are connection string settings in the Web.config for all supported databases, make sure you edit the one for the db you are using. Actually, you may prefer to put your connection string in a user.config file. Using a text editor, open the file user.config.sample (from the root of the Web folder) and save it as user.config, then edit the correct connection string in this file instead of touching the web.config. The settings in the user.config will override the settings in the web.config. This is especially handy for working from svn because you can get updated web.config settings without any conflicts. When you deploy on production delete the user.config and just use the web.config. Be aware that changes to user.config are not detected right away like changes to web.config so sometimes in order to make changes in user.config take effect, you have to type a space into web.config to change it in order for the updated user.config to be picked up.
As long as your db is setup correctly and your connection string is correct and you have set the correct reference to the Data layer you want from the mojoPortal.Business project you should be ready to go. If you got everything right you should now be able to click the Play button or choose "Start Debugging" from the Debug menu. This will compile the solution and open the site in the browser. The very first time you run it, it will throw some exceptions because there is no content yet in the db and the upgrade scripts have not yet been run. Just keep clicking the Play button (or F5) to continue execution, it will handle the exception and check if it needs to run upgrade scripts. It will run these scripts automatically as long as you don't stop execution.
Optional IIS Web Setup
If you would rather use IIS, configure a Virtual Directory in IIS so that http://localhost/mojoportal maps to the Web folder. Next you have to make the Data Folder beneath the Web writable by the ASP.NET worker process. Right click this folder in Windows Explorer and select the Security tab, add the ASPNET user (or on Win Server 2003 the IIS_WPG user) (In XP, if you don't see the Security Tab then google XP Simple File Sharing and you will find how to enable it)
If you run into any difficulties post in the Developer forum and I'll try to help.
If you fix a bug and you would like to contribute you can create patch files to send me by either right clicking a folder with changed files or right clicking a single file and choosing TortoiseSVN > Create Patch
Note that if you added new files you need to right click the new files and choose TortoiseSVN > Add before you create the patch file. Please do SVN Update to get up to the latest code before making patch files.
Tip: If you're interested in how to develop your own custom features for mojoPortal, open the WebStore.sln file and study the WebStore projects. I am implementing e-commerce as an external feature so you will be able to see a good example of a complex feature implemented using projects separate from the mojoPortal core. The e-commerce project is still underway but its a good reference project to learn how to setup you own custom external feature. There are some Flash movie tutorials here that may also help: http://www.mojoportal.com/creatinganewfeaturemodule.aspx
Last Updated 2007/05/29