Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7043259
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T02:16:03+00:00 2026-05-28T02:16:03+00:00

I am currently working on an ASP.NET MVC3 website. I have a simple authentication

  • 0

I am currently working on an ASP.NET MVC3 website.

I have a simple authentication form, binded on a simple viewmodel. When debugging on local, everything works fine.

But the website has to wotk on Apache + monomod too. And here is the strange behavior I encounter: the same form, with the same requests and parameters, are nto working.

More details:

The viewmodel:

/// <summary>
/// Form authentication info
/// </summary>
public class LogOnModel
{
    /// <summary>
    /// 
    /// </summary>
    [DisplayName("Username")]
    public string UserName { get; set; }

    /// <summary>
    /// 
    /// </summary>
    [DisplayName("Password")]
    public string Password { get; set; }

    /// <summary>
    /// 
    /// </summary>
    [DisplayName("Remember me?")]
    public bool RememberMe { get; set; }

    /// <summary>
    /// Targeted URL
    /// </summary>
    public string Target { get; set; }

    /// <summary>
    /// 
    /// </summary>
    public LogOnModel()
    {
    }
}

The main part of the view, page where the user can enter its username and password :

<%@ Page Title="" Language="C#" Inherits="System.Web.Mvc.ViewPage<Website.Areas.Public.Models.LogOnModel>" %>
<p>
    Please enter your username and password to continue.
</p>
<% using (Html.BeginForm())
   { %>
<%= Html.ValidationSummary(true, "Authentication failed.")%>
<p>
    <%= Html.ActionLink("I forgot my password","PasswordRecovery","Home") %>
</p>
<div>
    <fieldset>
        <div class="editor-label">
            <%= Html.LabelFor(m => m.UserName) %>
        </div>
        <div class="editor-field">
            <%= Html.TextBoxFor(m => m.UserName) %>
            <%= Html.ValidationMessageFor(m => m.UserName)%>
        </div>
        <div class="editor-label">
            <%= Html.LabelFor(m => m.Password)%>
        </div>
        <div class="editor-field">
            <%= Html.PasswordFor(m => m.Password) %>
            <%= Html.ValidationMessageFor(m => m.Password) %>
        </div>
        <div class="editor-field">
            <%= Html.CheckBoxFor(m => m.RememberMe) %>
            Remember me
        </div>
        <p>
            <input type="submit" value="Connect me!" />
        </p>
    </fieldset>
</div>
<% } %>

And the controller, receiving the auth infos :

    [HttpPost]
    public ActionResult LogOn(LogOnModel model)
    {
        string username = model.UserName;
        string password = model.Password;

        //On Apache, username & password are empty
       ...
    }

As I say in the comments, username & password are empty. Everything is working fine on a local ASP.NET debug server, and using Fiddler I can see that the requests for authentication contains form data (username, password, etc).

Any idea why the binding seems not to be working?
Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T02:16:03+00:00Added an answer on May 28, 2026 at 2:16 am

    Just found my answer, many months later. It’s a bit late but if anyone has the same problem, here’s the solution :

    Clean the Web.config file. Delete every lines that are optionnals

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently working on an ASP.NET MVC3 project in Visual Studio. I have
I have a site that I am currently working on in ASP.NET 2.0 using
I am currently working out of the Pro Asp.net mvc3 Framework book by Adam
I'm working on a large Asp.Net MVC3 application (>50 views) and we are currently
I am creating an ASP.NET MVC 3 e-commerce website and I am currently working
I'm working on MVC3 and currently creating a Forum application in asp.net. Forum allows
I am currently working on a ASP.NET MVC 3 project in which I have
I'm working in asp.net mvc3 and have partial views for my tabs and log-in
I am currently working on an ASP.NET MVC 3 app where I have a
I'm currently working on an ASP.NET Website where I want to retrieve data from

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.