Quel webconfig pour une business application ?
Bonjour,
J'ai un petit souci avec mon fichier WebConfig.
En fait je suis obligé de commenter une ligne dans le bloc "connectionStrings" quand je travaille à partir de Visual Studio et de la décommenter avant de publier. Pas mortel, mais pas très pratique.
Je dois sûrement avoir une erreur quelque part dans mon WebConfig, le voici donc:
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75
|
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<appSettings />
<connectionStrings>
<add name="JConnectionString" connectionString="Data Source=s23.myProvider.com;Initial Catalog=DB_111_biplan ;Persist Security Info=True;User ID=DB_111_biplan_user;Password=A1b2c3d4" providerName="System.Data.SqlClient" />
<!--LA LIGNE SUIVANTE DOIT ETRE DECOMMENTEE POUR UNE PUBLICATION ET COMMENTEE POUR TRAVAIL EN LOCAL-->
<add name="LocalSqlServer" connectionString="Data Source=s23.myProvider.com;Initial Catalog=DB_111_biplan ;Persist Security Info=True;User ID=DB_111_biplan_user;Password=A1b2c3d4" providerName="System.Data.SqlClient" />
<!--FIN-->
<add name="DB_111_biplanEntities" connectionString="metadata=res://*/JEdmx.csdl|res://*/JEdmx.ssdl|res://*/JEdmx.msl;provider=System.Data.SqlClient;provider connection string="Data Source=s23.myProvider.com;Initial Catalog=DB_111_biplan;Persist Security Info=True;User ID=DB_111_biplan_user;Password=A1b2c3d4;MultipleActiveResultSets=True"" providerName="System.Data.EntityClient" />
</connectionStrings>
<system.web>
<roleManager enabled="true">
<providers>
<clear />
<add name="AspNetSqlRoleProvider" connectionStringName="JConnectionString" applicationName="/" type="System.Web.Security.SqlRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
</providers>
</roleManager>
<!--bloc suivant rajouté pour authentification distante-->
<membership>
<providers>
<clear />
<add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="JConnectionString" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" applicationName="/" requiresUniqueEmail="false" passwordFormat="Hashed" maxInvalidPasswordAttempts="10" minRequiredPasswordLength="5" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" passwordStrengthRegularExpression="" />
</providers>
</membership>
<httpModules>
<add name="DomainServiceModule" type="System.ServiceModel.DomainServices.Hosting.DomainServiceHttpModule, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</httpModules>
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
</assemblies>
</compilation>
<authentication mode="Forms">
<!--<forms name=".JBase_ASPXAUTH" />-->
</authentication>
<profile>
<properties>
<add name="FriendlyName" />
</properties>
</profile>
</system.web>
<system.webServer>
<validation validateIntegratedModeConfiguration="false" />
<modules runAllManagedModulesForAllRequests="true">
<add name="DomainServiceModule" preCondition="managedHandler" type="System.ServiceModel.DomainServices.Hosting.DomainServiceHttpModule, System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</modules>
<security>
<authentication>
<basicAuthentication enabled="false" />
</authentication>
</security>
</system.webServer>
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
</system.serviceModel>
</configuration> |
En fait, mes tables ASP sont contenues dans la même base de donnée que celle qui contient les données de mon application.
Est-ce qu'un expert peut m'aider ?