rmcbride@rama.com
2009-04-24T07:19:11Z
Here is my first cut at installation instructions for YAF in a subdirectory with MMF. I can't attach a document, so here is the full text in this message. Sorry. :(

YetAnotherForum.NET (YAF) INSTALLATION FILE

YAF Setup Instructions for sub-site with Microsoft Membership Framework enabled.

STEP 1. UNZIP

Unzip the entire archive to to a folder you want to run YAF in on your web server.

STEP 2. SELECT WEB.CONFIG FILE

If you are upgrading an existing YAF installation please be careful and follow
a few precautions: ALWAYS BACKUP YOUR DATABASE BEFORE ATTEMPTING AN UPGRADE.

IMPORTANT: UPGRADING YAF FORUMS v1.9.1.x and BELOW:

You need to copy and rename the "/webconfigs/v191-upgrade-web.config" to "/web.config" as it
contains necessary settings for the YAF membership providers to support backwards
compatibility with your older YAF database. It's required that you merge these settings
into your existing "web.config" file. If you need to do development with an
upgraded installation, please use "/webconfigs/dev-v191-upgrade-web.config".
A tip to merge web.config files is to download both of them, then use a merge program to
combine. WinMerge is a free and excellent merge program which you can download
here: http://www.winmerge.org/ 

IMPORTANT: UPGRADING YAF FORUMS v1.9.3 BETA, RC1 and RC2:

You need to MERGE the changes for the /webconfigs/recommended-web.config or the
/webconfigs/v191-upgrade-web.config depending on the original web config you used -- the
membership provider settings have changed.

NEW INSTALLATION:

If you are starting with a new installation, we recommend you start with
"/webconfigs/recommended-web.config" and copy/rename it to "/web.config."
The "/webconfigs/recommended-web.config" files contains better default
ASP.NET security settings for a NEW installation of YAF.
If you are doing development, use the "/webconfigs/dev-recommended-web.config"
instead.

Please Note: These web.config files will not work if you are upgrading from v1.9.1.x
or below of YAF.

Warning: DO NOT edit the web.config unless you know what you're doing.

STEP 3. SETUP DATABASE (IGNORE IF UPGRADE)

A existing database needs to exist on your SQL Server with proper permissions
set so that YAF can access it. When you run YAF for the first time it will
detect that the database is empty (or needs upgrading) and will automatically
run you through the process required to create the SQL database structures
needed.

STEP 4. MODIFY DB.CONFIG FILE:

Modify the yafnet connectionString property to use your SQL Server database.
The database must exist on the server with proper permissions, but it can be
empty. Need help with your connection string? Visit this url:

http://www.connectionstr...t.aspx?carrier=sqlserver 

Look under the heading for "SqlConnection (.NET)" for example connection strings.

STEP 5. Relocate /bin and /App_Code to webroot.

By default YAF is designed to be installed at the root application on any
IIS web server. If you want YAF to be installed off of the main root, you need
to modify the root key.

In order for YAF to function in a sub-directory, the contents of the /bin directory
and the /App_Code directory need to be copied to the root of your website application.

In addition you will need to copy the App_Code folder to the root of your website.

STEP 6. MODIFY "app.config" FILE:

Then open up "app.config" and uncomment the "root" key. Enter the value as the
directory to your forum.

Example: If you have install the forum in the directory "/forum/yaf/"
you will need to add key with name "root" and value "/forum/yaf/"
to app.config. Here is an example where the forum is in a sub-directory
called "forums". <add key="YAF.Root" value="/forums/"/>

You will also have to change your BaseURL setting to reflect the location of your
forum. For example, if your forums are in <webroot>/forums, you would change the
BaseURL key to <add key="YAF.BaseUrl" value="~/forums" />.

Also, in "app.config" you can modify the BoardID to use the board you want.
If you only have one board or don't know what this is, leave it alone.

STEP 6a.

If you are using the Microsoft Membership Framework on your root website application,
your root web.config will have settings for Role Manager and Provider. These settings
will conflict with the default YAF settings in the YAF web.config. Therefore you will
need to open the YAF web.config and comment out or remove the following sections.

<!-- This is the original YAF configuration for roles.
<roleManager enabled="true" defaultProvider="YafRoleProvider">
<providers>
<clear/>
<add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafRoleProvider" type="YAF.Providers.Roles.YafRoleProvider"/>
</providers>
</roleManager>
<membership defaultProvider="YafMembershipProvider" hashAlgorithmType="SHA1">
<providers>
<clear/>
<add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafMembershipProvider" requiresUniqueEmail="true" useSalt="true" type="YAF.Providers.Membership.YafMembershipProvider"/>
</providers>
</membership>
<profile enabled="true" defaultProvider="YafProfileProvider" inherits="YAF.Classes.Utils.YafUserProfile">
<providers>
<clear/>
<add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafProfileProvider" type="YAF.Providers.Profile.YafProfileProvider"/>
</providers>
</profile>
-->

STEP 7. (OPTIONAL) MODIFY "mail.config" FILE:

Modify the smtp settings by entering your mail server information.

STEP 8. NEW INSTALLATION:

Open the file <YAFroot>install/default.aspx on your web site. If you
are testing on your local computer, under a directory called
YetAnotherForum.Net, the address should be:
http://localhost/yetanotherforum.net/install/

Follow the installation wizard directions and you should be able to log
in with the administration account you created during the setup.

Give the ASPNET/Network Service account write access to the Upload
folder.

STEP 9. UPGRADE:

Open the file <YAFroot>install/default.aspx on your web site. If you
are testing on your local computer, under a directory called
YetAnotherForum.Net, the address should be:
http://localhost/yetanotherforum.net/install/

The wizard will guide you through the upgrade process.



If you have any questions, please visit the YAF Support forum:

http://forum.yetanotherforum.net 

We'll be happy to help. But please remember YAF is supported by volenteers.

YAF Support (support@yetanotherforum.net)

Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer Topic Starter
2009-04-24T12:36:54Z
rmcbride@rama.com
2009-04-24T14:30:22Z
More to come once we discover what is happening with the Object reference errors. In addition, if you want the YAF images you have to move them to the root images folder too. I suspect that will include the Avatar images, but I haven't gotten that far yet. I am stalled with the object reference problems.
TommyB
2009-04-24T20:33:34Z
I've had to recompile yaf anyway so I fixed this error for me.
This should work for you, too (Fixes only the System.Web.Extensions v3.5 reference bug as described earlier in here)

Download YAF193FW20_ReferenceHotfix.zip 
Copy this 2 files into your /Bin directory (whereever it is placed now ^^) and replace the existing ones.


ps: I also agree with rmcbride, upload access would be nice for this cases 😉
- Sry for my english ;)

BattCursor.Net  - Official homepage of that tool for vista laptops!
flow7oo
2009-04-25T00:48:29Z
I've managed to do a fresh install, but now I'm getting this...am I missing something?

Server Error in '/' Application.
The control with ID '' requires a ScriptManager on the page. The ScriptManager must appear before any controls that need it.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.InvalidOperationException: The control with ID '' requires a ScriptManager on the page. The ScriptManager must appear before any controls that need it.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[InvalidOperationException: The control with ID '' requires a ScriptManager on the page. The ScriptManager must appear before any controls that need it.]
System.Web.UI.ExtenderControl.get_ScriptManager() +607212
System.Web.UI.ExtenderControl.RegisterWithScriptManager() +110
AjaxControlToolkit.ExtenderControlBase.OnPreRender(EventArgs e) +52
System.Web.UI.Control.PreRenderRecursiveInternal() +108
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3394

We’ve gone on holiday by mistake! Are you the farmer?
Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer Topic Starter
2009-04-25T00:55:01Z
Which version of .NET are you running?
Jaben
  •  Jaben
  • 100% (Exalted)
  • YAF Developer Topic Starter
2009-04-25T01:06:08Z
release updated with NET v2.0 fixes and user_delete fix.
mothswiller
2009-04-25T03:20:36Z
rmcbride@rama.com wrote:

When I go to do the "Install", I get the following error...

Server Error in '/' Application.

Configuration Error

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: 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.

Source Error:


Line 103: </pages>
Line 104:
Line 105: <roleManager enabled="true" defaultProvider="YafRoleProvider">
Line 106: <providers>
Line 107: <clear/>

Source File: C:\inetpub\wwwroot\forums\web.config Line: 105

I was expecting this, as I have seen this in the past. The problem is that I am not sure at this point what to do. This looks like a conflict between my current role provider, which is set to default, and the YAF role provider. In addition I think the role provider stuff has to be in the root web.config, but I am not sure about this.

So at this point I am stalled (unless I go hacking about on my own, which I am going to do, but kind of defeats the purpose of this experiment, so I will do my best to track my hacking.)

thanks

Richard




This problem can occur if you are running in medium trust - the call requires full trust. I notice in the Final release the YAF.Providers assembly is now marked as AllowPartiallyTrustedCallers however there is still an error because although the YafMembershipProvider class is now public the YafProfileProvider class still remains with no access modifier - see my thread on this here 

rmcbride@rama.com
2009-04-25T06:06:49Z
hi Jaben

Should I download the release again today and retry. In other words, are there fixes in YAF-v1.9.3-FINAL-BIN-NET35 today that were not there a couple of days ago?

Hi TommyB

I copied the two files in the link provided, but still generate those errors. Perhaps I should get the source code and recompile it here. I have Visual Studio, both express and full version.

What IDE are you compiling in? I have never compiled an open-source project before, so it might be an interesting experience.

Thanks

Richard
rmcbride@rama.com
2009-04-25T06:10:19Z
Hi mothswiller

I have heard a lot about the medium trust issues, but there is also a simpler explanation. Did you set up your website with asp integrated authentication? If so, then you need to comment out those lines in the YAF web.config file. You can`t have two competing membership frameworks.

If not, then you can`t call the membership framework from a sub-directory, so you will have to move the YAF membership lines to your root web.config.

So perhaps the real question is -- what is your installed environment and directory structure?

Thanks

Richard
TommyB
2009-04-25T06:13:43Z
strange, they works for me 0.o
Well it was a try, but the new release should fix the problem I think :)

I use visual studio 2008, but sharpdevelop (open source) should be able to compile it, too (but I havent tested it yet)

- Sry for my english ;)

BattCursor.Net  - Official homepage of that tool for vista laptops!
rmcbride@rama.com
2009-04-25T06:16:18Z
I am assuming that downloading via the website like will give the latest and greatest. I did not see any sub-rev numbering, so I am not sure, but I will give it a shot. As to why your dll`s did not work for me, it may be an environment thing. We shall see.

Are you set up in a sub-directory structure using asp membershipsÉ

Thanks

Richard
TommyB
2009-04-25T06:22:25Z
I have installed it as a subdomain as you may see on my page :)
It is a single application, where root is root and everything's fine 😉
- Sry for my english ;)

BattCursor.Net  - Official homepage of that tool for vista laptops!
rmcbride@rama.com
2009-04-25T06:37:39Z
Hi TommyB

Ah! There is the difference. My installation is in a sub-directory off the root, where the root application is the application and where authentication is provided by asp membership at the root application.

I think this subdirectory thing is causing all these object reference issues for me, and for many others.

Thanks

Richard
rmcbride@rama.com
2009-04-25T06:38:44Z
By the way folks, I think we need to move this discussion over to the Integration forum.

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