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 6908363
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T08:33:14+00:00 2026-05-27T08:33:14+00:00

Have an ASP.NET MVC3 app with model validation using FluentValidation . User enters some

  • 0

Have an ASP.NET MVC3 app with model validation using FluentValidation. User enters some html in a regular text field, and is presented with a user-friendly error on submit (because of the “A potentially dangerous Request.Form value” error).

What I’d really like to do is show a validation message right on the form itself (“Oops, no html allowed”) which shows up right next to the field – similar to model validation errors. That way, the user (malicious or not), knows about it before the entire form is actually filled out and submitted.

Would appreciate any ideas on how to go about implementing this apart from what’s shown here (i.e. without having to add [AllowHtml] + a regex to almost every field in almost every viewmodel)

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-27T08:33:15+00:00Added an answer on May 27, 2026 at 8:33 am

    You will need to write a custom ProertyValidator for server-side FluentValidation with client-side support. I think you can follow this article, here, to create client-side jquery validation rule and the adapter.

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

Sidebar

Related Questions

I have an asp.net mvc3 Razor app being developed in VS2010 using Git for
I have asp.net MVC3 app where validations are done by adding validation attribute in
I have ASP.Net code generating my button's HTML for me using divs to get
I have ASP.NET dropdown which is too small to display full text the user
I have an ASP.NET MVC3 app that features a form with a nested-table input
I'm currently developing an app using ASP.NET MVC3 and Entity Framework 4.1 Code First
Here's the issue at hand: I have developed an ASP.NET MVC3 application using Razor.
While developing my app (asp.net mvc3) locally everything was fine using the VS dev
I have an ASP.NET MVC 3 app that is using SQL Server CE 4.0
I have an asp.net MVC3 app with various bits of form data and a

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.