request-validation Questions
3
Solved
Lets say I have the following Custom Request:
class PlanRequest extends FormRequest
{
// ...
public function rules()
{
return
[
'name' => 'required|string|min:3|max:191',
'monthly_fee...
Mccrary asked 22/12, 2017 at 5:36
2
Solved
So i'm working on validating a form's inputs using the following code:
$request->validate([
'title' => 'bail|required|max:255',
'body' => 'required',
]);
So basically, there are two f...
Cree asked 17/12, 2019 at 10:25
5
We've just upgraded to ASP.NET 4.0, and found that requestValidation no longer works. The MSDN docs suggest we need to set requestValidationMode in web.config to 2.0:
4.0 (the default). The Ht...
Subtraction asked 12/10, 2011 at 13:36
8
Solved
The question is already asked here for a previous version of laravel and not yet answered.
I have a html form which is validated using three different Form Request Validations. I am able to do th...
Charlinecharlock asked 21/1, 2018 at 19:35
1
I have a controller method of this signature:
public async IAsyncEnumerable<MyDto> Get()
It works fine but I need to do some request validation and return 401, 400, and other codes accordi...
Roswell asked 9/3, 2020 at 11:27
3
I'm using ASP.NET WebForms (.NET 4.5) and have an "content block" control, which is reused on a number of pages. I've tried setting the ValidateRequestMode of the control and even individual elemen...
Chub asked 13/5, 2014 at 14:13
7
Solved
So I'm trying to develop a rest API for an internal project, and I've got an issue where when the form request validation fails, it shows the @index response.
So I have two routes;
Route::get('/a...
Corded asked 21/9, 2017 at 17:52
1
Solved
I setup AWS API Gateway with CORS successfully, when a request is valid I have a 200 status code and also CORS headers, that's nice.
But when AWS API Gateway Request Validator detects an invalid i...
Frediafredie asked 9/2, 2018 at 16:56
4
We've configured our custom error pages as below for exceptions thrown by ASP.NET:
<customErrors mode="On" redirectMode="ResponseRewrite">
<error statusCode="400" redirect="~/400.aspx"/&...
Carlton asked 11/1, 2014 at 22:2
2
Solved
I'm having a problem with request validation in ASP.NET webforms that I am fairly sure is down to me hosting a .NET 3.5 project on IIS 7.5 (Windows 7 - local development machine).
Essentially I'm...
Hadleigh asked 6/5, 2011 at 11:16
4
Solved
I have been going through the error logs of a development project and found the following error (name changed to protect the guilty innocent)-
The provided anti-forgery token was meant for user ...
Antislavery asked 30/9, 2013 at 14:25
4
Solved
I'm having problems with requests that include 'dangerous characters' as part of a Web API URL. The Url includes an & which is properly Url encoded, but still causes a Request Validation ASP.NE...
Overmuch asked 14/3, 2012 at 8:28
1
Solved
I'm using angular 1.0.4 with an ASP.NET MVC4 + Web API project. I'm trying to leverage angular's CSRF protection to no avail. I can see that I'm passing along a cookie named XSRF-TOKEN, but when an...
Susette asked 16/3, 2013 at 2:5
1
Solved
My question is hopefully pretty straight forward.
Upon submitting my form, I would like to flag all properties (fields) that have invalid characters (specifically HTML) as model errors.
The issue I...
Unkenned asked 13/2, 2012 at 14:50
4
Solved
I am trying to turn off Request Validation for all action methods in a controller by doing this:
[ValidateInput(false)]
public class MyController : Controller
{
...
The reference I am using says ...
Stuyvesant asked 10/7, 2009 at 15:59
2
Solved
Has request validation changed for ASP.NET MVC 2, more precisely, not validating?
I did the following:
Web.configs (in App directory and Views directory)
<pages
validateRequest="false"
Con...
Toogood asked 30/10, 2009 at 6:57
1
© 2022 - 2024 — McMap. All rights reserved.