Posted by: rmcbride@rama.com - Wednesday, 8 April 2009 22:35:48
Hi all
I have a bit of a different take on the login integration question. I have an existing site and have added YAF successfully. (WooHoo!!).
Now I want to add a membership component to the website. Since YAF is in place, is there a way that I can simply use the YAF login process for the whole website?
Thanks
Richard
Posted by: mddubs - Thursday, 9 April 2009 05:27:06
If you used the Membership framework for your YAF login then yes it's very easy. If not, you'll just have to figure out how YAF membership works and use that.
Posted by: rmcbride@rama.com - Thursday, 9 April 2009 13:50:52
I haven't actually built the member site yet, so I will start with the Microsoft Membership Framework and build with integration in mind.
Thanks
Posted by: rmcbride@rama.com - Friday, 10 April 2009 09:15:45
So I have setup my site with Microsoft Membership Framework using ASP.NET. What would be the next step to getting YAF to use the MS Membership login information. Please keep it really direct and simple, and use examples if at all possible. I am a complete noob at this stuff. Consider that it has taken me two days to get the MS Membership stuff working:!:
Thanks
Richard
Posted by: mddubs - Friday, 10 April 2009 10:24:26
Just edit the Membership Provider settings in YAFs web.config to use your Membership Framework system.
Posted by: rmcbride@rama.com - Friday, 10 April 2009 10:50:10
Hi
The web.config in my YAF folder (aka forums) consists of the following 6 lines...
I have it working as a subfolder in the existing application. Is there a different file (eg yafnet.config or the root web.config) that might contain this information?
And I want to let you know that I am very appreciative of your help with this. I thought it should be a simple thing and I am sure once I get the details figured out it will be.
Thanks
Richard
Posted by: mddubs - Friday, 10 April 2009 10:56:41
Use version 1.9.3. Previous versions don't work with the Membership framework.
Posted by: rmcbride@rama.com - Friday, 10 April 2009 11:05:11
Will do.
Thanks
Richard
Posted by: rmcbride@rama.com - Friday, 10 April 2009 13:23:35
Hi
This must be reallllly trying your patience. I can see all the people asking these same questions, so I understand why you might be tired of answering them.
So I hosed my 1.9.1.8 environment and installed the 1.9.3 version. It's a bit tricky doing it as a subdirectory, although I had it working fine in the previous version and I have not doubt my current issue is a really simple one.
I have done everything and gotten the install complete. But when I go to the forum site I get the following error.
I have the dlls in the root/bin folder and my "root" line in app.config reads as follows.
The actual path to YAF is webroot/forums. I am fairly sure I have buggered up my web.config or app.config somehow, and I suspect is has something to do with the root key but I have tried pretty much every variation.
Suggestions?
Thanks
Posted by: rmcbride@rama.com - Friday, 10 April 2009 13:25:40
Oops.
I meant this as the error.
System.ApplicationException: Failed to get configuration from Web.config.
Source Error:
Line 44:
Line 45:
Line 46:
Line 47:
Line 48:
Thanks
Richard
Posted by: rmcbride@rama.com - Friday, 10 April 2009 13:28:40
and if I call the forums directly instead of via the control, I get the following..
Unknown server tag 'YAF:Forum'.
Source Error:
Line 18:
Line 19:
Line 22:
Interestingly enough, it is probably the same issue, so I am still stuck here.
Thanks
Richard
Posted by: rmcbride@rama.com - Friday, 10 April 2009 13:59:39
javascript:insertsmiley(':) ','/images/emoticons/icon_smile.gif')
GOT IT!!!
Oddly enough, the App_Code directory did not make the trip in the unzip. It was missing! So when I started poking around looking for things, I couldn't find them. So I checked the structure in the zip file and there it was!
Thanks for all you patience.
Richard
Posted by: rmcbride@rama.com - Friday, 10 April 2009 14:28:15
OK, so now that I actually have YAF working, I need to edit the web.config to get YAF to use the same role provider as my website.
Right now my website is using the default SQL provider that is nice and easy to install and setup. However that "inherited" functionality has no settings in the web.config file. So I am not sure what to do here.
Given that my SQL server is "myserver", the membership database is currently aspnetdb, and the connection strings are working, what should I modify in the following to get YAF to use aspnetdb?
Or should I go the other way and make the YAF provider the provider for the whole website? That would also be fairly easy I suspect.
Thanks
web.config snippet below...
Posted by: rmcbride@rama.com - Friday, 10 April 2009 14:32:06
I did it the YAF way and it was dead simple. One selection on my login control and now my whole website is using the YAF login structure. No need for me to have a different user database.
This is definitely the way to go.
Now, on to testing!