Questions tagged [laravel-request]

Laravel Requests - handling request and Request validation

218 questions
-1
votes
2 answers

how to use the form(checkbox) to pass the user id

I have a table in it there are checkboxes I need that on those users on which the checkbox is selected their id was transferred my form
QIPS
  • 1
  • 4
-1
votes
1 answer

How to dd the value in database?

I want to check the value in the database whether it is the same with the form value. How can I view the value in database using dd syntex? dd('status'); $updateForm = Form::where('reference_no',$r->refer) -> update([ 'status' => $r->sts, …
-1
votes
2 answers

Uploading File with CURL and Retrieving in Laravel Method

I'm trying to get data posted using cURL in my endpoint, which is built on Laravel. In my API controller, where I receive data, I am able to receive all the data except my media file. I check for presence of the file using $request->hasFile('file')…
CodeNewbie
  • 49
  • 3
  • 11
-1
votes
1 answer

Using value of controller in the model Laravel

This is my model code, and what I'm trying to get is the number of products that a user wants to add to his cart (quantity). My problem is how do I pass the value that I'm getting in the controller through a request to my model because it's there…
Daniel Hernandez
  • 195
  • 6
  • 17
-2
votes
1 answer

Laravel 9 Validator Make Method Not Working

I have written this code in the Controller as the Action of a form: public function submitAsk(Request $request) { $rules = [ 'title' => 'required|max:255', 'description' => 'required|max:1000', …
Pouya
  • 114
  • 1
  • 8
  • 36
-2
votes
2 answers

How to show only one error message from Laravel request rules

I am using Laravel request to validate in my controller the requested data and here is my request file data I am facing two challanges first I am not able to return custom message using static function I am not able to send single message as we…
Mannu saraswat
  • 1,061
  • 8
  • 15
-4
votes
1 answer

How to combine these regex expressions together

I'm working with Laravel and I have used this custom regular expression for validating user password request: 'user_password'=> ['required','min:6','regex:/[a-z]/','regex:/[A-Z]/','regex:/[0-9]/','regex:/[@$!%*#?&]/'] Now I needed to combine these…
demovow182
  • 87
  • 5
-5
votes
1 answer

how to get form $request all data in Laravel Model

This is learning purpose question. I have a form and after submit the form i want to catch this form all request data into the model. so how to do this? thanks.
mahbub
  • 103
  • 1
  • 3
  • 13
1 2 3
14
15