How to Install YAF

Last week I decided to install some forums engine for my web site. A few years ago I used Microsoft's starter kit for forums on one of our other sites. That code was done in Microsoft .Net 1.1. Now I needed to look for some code base that was done using latest and greatest changes to .Net framework (3.5 or higher). Finally I ran into Yet Another Forum (YAF). After doing a quick review of the code base it looked promising and I decided to install it. During the installation I ran into some minor snags. So I thought I will share some experience here for benefit of our readers.

First I will recommend the instructions on YAF site. It provides very elaborate instructions on what components to download and where to put. I am just going to cover the topics that may need some more explanation. Mind it that these instructions are when you are compiling the source code yourself and then deploying the application.

  • After you have deployed all the binary files, pages and controls etc., you will need to modify all the config files. The application has following config files in the root folder.
    • web.config: This file is pretty much empty in source code folder. But there is a folder named webconfigs which has recommended config file entries. I would recommend copying the control from recommended-NET-web.config into your file.
    • db.config: This file contains connection string for your database. Modify or add the entries accordingly. The important part in this entry in name of the connection string. By default this name is set to yafnet. Leave it that way because this is the name set in apps.config file. If you want to use a different name of your connection string, then you will need to modify value for YAF.ConnectionStringName in app.config file as well.
    • mail.config: This file contains settings for SMTP server that you will be using to send emails from forum. Modify entries in this file to configure email capability for your application.
    • urlrewriter.config: This file contains how URL rewrite works for different kinds of request URLs for your application. You can leave it unchanged unless you are trying to implement some custom rules of your own.

    These are all the config files you got to modify to install YAF.

  • Once you have modified config file, just invoke http//www.myforumsite.com/install/default.aspx. You can invoke default page of your application as well. It automatically detects if you have completed installation of your application or not. If installation is not complete, it automatically launches installer for the forum. Follow the instructions of installer and you should be all set to go.

Some recommendations

After you have completed installtion I will strongly recommend removing Install folder from the application or secure it by putting a web.config file that restricts access to authorized users. If you do not do it, then you leave the room open for a hacker to launch installer which will attempt to modify your installation. Installation will not work without admin password but you still leave room open for somebody to guess password and possibly trash your site.

Here is link to blog that I installed using these instructions. ByteBlocks Forums.

Search

Social

Weather

-1.8 °C / 28.8 °F

weather conditions Clouds

Monthly Posts

Blog Tags