title: ASP.NET MVC app works in debug but not when published using Plesk and GoDaddy
body: <p>I have an MVC app that works perfectly in debug mode and testing, but after I publish using ftp to godaddy, the website opens up and works when toggling between the home page and the login page. If I try logging in I get an error or if I try using the search box on my homepage, I also get an error. Here is the screenshot: <a href="https://i.stack.imgur.com/s5QCj.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/s5QCj.png" alt="Error"></a></p>
  
  <p>After I log in or basically anything or than <code>'mydomain'.com/Home/Index/</code> I get this error, if I try <code>'mydomain'.com/Home/Search</code> or <code>'mydomain'.com/Search/Index</code> any other controller or action I get this. What could be the cause because I have tried everything? For example is HomeController/Search: </p>
  
  <pre><code>public ActionResult Search(string search, string searchlast)
      {
          var doctors = from d in db.Doctors
                        select d;
          if (!String.IsNullOrEmpty(search) || !String.IsNullOrEmpty(searchlast))
          {
              doctors = doctors.Where(d =&gt; d.FirstName.Contains(search) &amp;&amp; d.LastName.Contains(searchlast));
              return View(doctors.ToList());
          }
          return RedirectToAction("Index", "Home");
      }
  </code></pre>
  
  <p>Here is Views/Home/Search which gives the error:</p>
  
  <pre><code>@model IEnumerable&lt;Systemz.Models.Check&gt;
  @{
      ViewBag.Title = "Search";
  }
  
  &lt;div class="jumbotron"&gt;
      &lt;h2&gt;Check&lt;/h2&gt;
      &lt;h4&gt;Check for availability.&lt;/h4&gt;
  &lt;/div&gt;
  
  @using (Html.BeginForm("Search", "Home", FormMethod.Post))
  {
      &lt;p&gt;
          First Name: @Html.TextBox("search") Last Name: @Html.TextBox("searchlast")
          &lt;input type="submit" value="Search" name="search" /&gt;
          &lt;a asp-action="Search" asp-controller="Home"&gt;&lt;/a&gt;
      &lt;/p&gt;
  }
  
  &lt;table class="table table-hover dataTable"&gt;
      &lt;div class="row"&gt;
          &lt;div class="col-md-4"&gt;
              &lt;thead class="bd-dark white-text"&gt;
                  &lt;tr&gt;
                      &lt;th&gt;
                          Title:
                      &lt;/th&gt;
                      &lt;th&gt;
                          First Name:
                      &lt;/th&gt;
                      &lt;th&gt;
                          Last Name:
                      &lt;/th&gt;
                      &lt;th&gt;
                          Address:
                      &lt;/th&gt;
                      &lt;th&gt;
                          Is Available?
                      &lt;/th&gt;
                  &lt;/tr&gt;
              &lt;/thead&gt;
              &lt;tbody&gt;
                  @foreach (var item in Model)
                  {
                      &lt;tr&gt;
                          &lt;td&gt;
                              @Html.DisplayFor(modelItem =&gt; item.Title)
                          &lt;/td&gt;
                          &lt;td&gt;
                              @Html.DisplayFor(modelItem =&gt; item.FirstName)
                          &lt;/td&gt;
                          &lt;td&gt;
                              @Html.DisplayFor(modelItem =&gt; item.LastName)
                          &lt;/td&gt;
                          &lt;td&gt;
                              @Html.DisplayFor(modelItem =&gt; item.Address)
                          &lt;/td&gt;
                          &lt;td&gt;
                              @if (item.IsAvailable == true)
                              {&lt;p&gt;&lt;a class="btn btn-success"&gt;&lt;/a&gt;&lt;/p&gt; }
                              else
                              { &lt;p&gt;&lt;a class="btn btn-danger"&gt;&lt;/a&gt;&lt;/p&gt;}
                          &lt;/td&gt;
                      &lt;/tr&gt;
                  }
              &lt;/tbody&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  &lt;/table&gt;
  </code></pre>