Welcome Guest! To enable all features please Login or Register.
Options
View
Go to last post Go to first unread
Offline Daeamon Dmitry  
#1 Posted : Saturday, April 29, 2017 8:40:12 AM(UTC)
Daeamon Dmitry


Rank: YAF Forumling

Reputation:

Joined: 4/29/2017(UTC)
Posts: 1
Man

Hi, i'm trying to integrate YafMembershipProvider with my application, but this does'not work((((
I'm add to references dll's from YAFNet and edit my web.config.
Code:

<membership defaultProvider="YafMembershipProvider" hashAlgorithmType="SHA1">
      <providers>
        <clear />
        <!-- YAF's ASP.NET Membership Provider is designed to work a bit better with YAF.NET options, but is by no means required.
             But, you will not be able to switch providers after installing your forum. -->
        <add name="YafMembershipProvider" applicationName="OlenObl" connectionStringName="DefaultConnection"
             requiresUniqueEmail="true" useSalt="true" type="YAF.Providers.Membership.YafMembershipProvider" />

        <!-- Uncomment and set as default if you want to use the built-in ASP.NET membership provider. Password Type of "Encrypted" requires a machine key. -->
        <!-- If you want to install YAF.NET inside Azure you need to use that Provider. -->
        <!--<add name="AspNetSqlMembershipProvider" applicationName="YetAnotherForum" connectionStringName="yafnet"
             enablePasswordReset="false" enablePasswordRetrieval="true" maxInvalidPasswordAttempts="5"
             minRequiredNonalphanumericCharacters="0" minRequiredPasswordLength="5" passwordAttemptWindow="15"
             passwordFormat="Encrypted" requiresQuestionAndAnswer="false" requiresUniqueEmail="true"
             type="System.Web.Security.SqlMembershipProvider" />-->
      </providers>
    </membership>

    <roleManager enabled="true" defaultProvider="YafRoleProvider">
      <providers>
        <clear />
        <!-- YAF's ASP.NET Role Provider is designed to work a bit better with YAF.NET options, but is by no means required.
             But, you will not be able to switch providers after installing your forum. -->
        <add name="YafRoleProvider" applicationName="OlenObl" connectionStringName="DefaultConnection"
                     type="YAF.Providers.Roles.YafRoleProvider" />
        <!-- Uncomment and set as default if you want to use use the built-in ASP.NET role provider. -->
        <!--<add name="AspNetSqlRoleProvider" applicationName="YetAnotherForum" connectionStringName="yafnet"
                     type="System.Web.Security.SqlRoleProvider" />-->
      </providers>
    </roleManager>

    <profile enabled="true" defaultProvider="YafProfileProvider" inherits="YAF.Utils.YafUserProfile">
      <providers>
        <clear />
        <!-- YAF's ASP.NET Profile Provider is designed to work a bit better with YAF.NET options, but is by no means required.
             But, you will not be able to switch providers after installing your forum. -->
        <add name="YafProfileProvider" applicationName="OlenObl" connectionStringName="DefaultConnection"
             type="YAF.Providers.Profile.YafProfileProvider" />
        <!-- Uncomment and set as default if you want to use use the built-in ASP.NET profile provider. -->
        <!--<add name="AspNetSqlProfileProvider" applicationName="YetAnotherForum" connectionStringName="yafnet"
                     type="System.Web.Profile.SqlProfileProvider" />-->
      </providers>
    </profile>


I get authorization error.
Screenshot_4.png
How do I change the AccountController.cs so that it all works?
Anyone help me?)
Maybe any one already has worked AccountController.cs for ะก# ASP.NET Mvc 4?
Sponsor
Offline tha_watcha  
#2 Posted : Monday, May 1, 2017 1:30:19 AM(UTC)
tha_watcha


Rank: YAF.NET Project Lead

Reputation:

Medals: Medal of Honor: Portal Puzzle Master: Portal Puzzle Master for DNNMedal of Honor Key: Given to pillars of the community who are key players in the YAF community and project.DNN Master: DNN Module ManBug Killer Medal of Honor: Medal for being a kick-ass bug killer!Medal of Honor for the Support King: Support King! Amazing asset to the YAF.NET Community.

Joined: 3/6/2010(UTC)
Posts: 3,721
Germany

Thanks: 70 times
Was thanked: 1147 time(s) in 977 post(s)
No that wont work directly you can not integrate yaf inside a MVC Applictation. The only solution would be to run YAF as separate application.
Rss Feed  Atom Feed
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Notification

Icon
Error