Daeamon Dmitry
  • Posts: 1
  • Joined: 29/04/2017
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.

<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?
tha_watcha
  • Posts: 4035
  • Joined: 06/03/2010
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.
UserPostedImage
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.

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