2009-10-23T15:36:22Z  to embed yaf inside my website but 70% of the instructions I can't follow because the files for items do not exist.

I am installing this on a dedicated machine and the "regular" install using a virtual directly works!


2. Move the yafnet.config file from ~/yaf to ~.
Ensure that the yafnet.config file "points" to the place where you have YAF installed, in the example case:


There is no yafnet.config file in the directory!


3. Modify ~/web.config.
You need to update your main site ~/web.config with most of the contents from the old ~/yaf/web.config. Leave out all the "rewriting stuff" as you're going to switched that off later anyway. Specifically, you seem to need the following. Check carefully where this stuff comes from in the old web.config and make sure you put it in the same sections in your site's web.config. It'll bitch at you if you don't. See additional notes below.:
<section name="yafnet" type="yaf.SectionHandler,yaf"/>
<yafnet configSource="yafnet.config"/>

Both said section do not exist


6. Copy or move ~/yaf/yaf.dll to ~/bin/yaf.dll

7. Copy or move ~/yaf/framehelper.aspx to ~/

Both do not exist!

I am really excited about this and have trying to install this for a few hours.. can someone point me to somewhat updated instructions?

  •  Jaben
  • 100% (Exalted)
  • YAF Developer
Please be more clear about which version you are trying to install.
Jaben wrote:

Please be more clear about which version you are trying to install.

Sorry, the latest one v1.9.4 beta 3. If I install 1.9.3 final would the instructions match up?

  •  Jaben
  • 100% (Exalted)
  • YAF Developer
Nope, doesn't look like it. The instructions are for the v1.9.1.8 -- which I don't recommend installing.

Just follow the instructions included with v1.9.4 -- if you have any questions ask them here.

"Embedding YAF" is very easy... Just look at the default.aspx page -- put the <YAF:Forum> tag in your own site page and include the code that references the YAF core classes.
ahh.. I see the <YAF:Forum> tag in default.aspx which means the whole thing can be a user control. Perfect!

Now just 2 more questions..
1. I need to copy all the .dll's from the YAF bin directly to the root bin directly?
2. Also, do I need to copy all the sections from YAF web.config to the root web.config?
Okay using v1.9.3

1. I copied the entire web.config from the YAF directory (one that I originally copied from sampleconfig directory and was working when YAF is run in Virtual Directly mode) to the root directory, then deleted web.config in YAF directory.
2. Copied all files from YAF bin directory to the root bin directly.
3. Changed YAF.Root in app.config to point to the YAF directly which resides as a folder "YAF" in my root directory.
4. Changed connection settings in my root web.config to point to the correct location
<connectionStrings configSource="YAF\db.config"/>
<appSettings configSource="YAF\app.config"/>
<rewriter configSource="YAF\URLRewriter.config" />
5. Copied default.aspx from YAF directory to my root directory.
6. Tried to run http://localhost/default.aspx

And.. I am getting "Parser Error Message: Unknown server tag 'YAF:Forum'." at <YAF:Forum runat="server" ID="forum"></YAF:Forum>

Any suggestions?
  •  logan
  • 100% (Exalted)
  • YAF Leader
Try this setup:
<add key="UploadDir" value="~/Forum/upload/" />
 <add key="root" value="~/Forum/" />
logan attached the following image(s):

  •  Jaben
  • 100% (Exalted)
  • YAF Developer
You need the App_Code directory in your root directory as well. The wonderful Mek has a guide that might help:

Thanks for the help guys, I feel like I am very close..

After following all the instructions I now get "System.ArgumentException: The virtual path '/YAF/pages/forum.ascx' maps to another application, which is not allowed"

Googling the error it seems like it has something to do with the root key/value pair

<add key="YAF.Root" value="/YAF"/> was already in app.config
I also added <add key="root" value="~/YAF/" />

In both cases I have tried all value combinations including ~/YAF, /YAF, /YAF/, ~/YAF/
  •  Jaben
  • 100% (Exalted)
  • YAF Developer
Maybe your /YAF directory IS an application root? That would explain that error. In that case, you don't need YAF.Root at all.
Volla! We have liftoff!

Although, I removed the application from IIS by clicking [Remove] in YAF virtual directly properties, the YAF application still exisited with a red x in IIS. As soon as I right clicked and deleted it completely, it started working!

Thanks for your help.

About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved