title: asp .net mvc website login/register works on local but not on server .net 4.5.2 vs2105
body: <p>I created an mvc website.
  Framework: .net 4.5.2 
  visual studio 2105 community edition.</p>
  
  <p>When I run project On my local machine, it works perfectly.
  I try to use register and login pages, they are working perfectly as well. I can create new users and then login with them.</p>
  
  <p>But when I copy project on server (Windows server 2012), project works perfectly but not register/login pages.</p>
  
  <p>It gives error: </p>
  
  <blockquote>
    <p>An error occurred while processing your request.</p>
  </blockquote>
  
  <p>I copied App_Data folder as well. There is a <code>.mdf</code> file in it.</p>
  
  <p>This is the connection string in web.config</p>
  
  <pre><code>add name="DefaultConnection" connectionString="Data Source=(LocalDb)\MSSQLLocalDB;AttachDbFilename=|DataDirectory|\aspnet-mvc1-20151111034033.mdf;Initial Catalog=aspnet-mvc1-20151111034033;Integrated Security=True"
        providerName="System.Data.SqlClient" 
  </code></pre>