aem99 aem99
30

What to return if no record was found

Hi, I have a scenario where I have a helper function that looks up latest product and returns it. As this function is called in few places I have placed it in its ow...
Eloquent
30
382
omarsow94 omarsow94
25

Unable to write in the "public/images" directory on macbook

Hello, i'm trying to upload image but got issue about permissions. public function postBook(Request $request) { $image = $request->fi...
Laravel
25
187
skinnyvin skinnyvin
23

$this is null inside model

I am in a tangle with counts and relations and noticed that $this is null on methods within the Store model. I am only interested in Visits belonging to the...
msslgomez msslgomez
23

401 Unauthorized while trying to load page

I've never seen this error before so I don't even know where to look or start to fix it, how can I check where this error is coming from in order to fix this? This e...
Laravel
23
113
manshu manshu
20

Creating User for API giving error

Here's my User Registration Test. I am using default UserFactory.php to create user. I am getting the following error. Illuminate\Validation\ValidationExcept...
Laravel
20
224
InspiredPrynce InspiredPrynce
19

Calculating retirement date

I have a program where there are staff records, it has a date of first appointment and also a date of birth. There are two modes of retirement in the civil service, if you...
General
19
219
scottbear scottbear
19

Relation not returning properties

Hello. I have two models composing a one to many relationship. Tickets and TicketMessages. In the Ticket model I have this two functions....
Laravel
19
122
myke2424 myke2424
18

Request null

I'm getting a return of null when i dump $request inside of my public function show() method. I'm trying to get this line to work: $times = Time::where('...
General
18
156
Heimdall Heimdall
18

The POST method is not supported for this rout

Hi, I want save information by my form on my DataBase but when i send information i have this error : The POST method is not supported for this route. Support...
General
18
162
matheenulla matheenulla
17

Laravel groupBy query (API Resource)

Hi I am trying to get a student marks details that are group by exam_type. I need to create a API in below format. But I am unable to do that one. I need help with b...
Laravel
17
193
towhid towhid
17

NEXT PREVIOUS Functionality in Single page view and going to next and previous item when i want .

i have many kind of collection , my favorite list, who favorite me list , my contact pick list , who contact me list . contact trashed list , favorite trash list , many k...
Laravel
17
245
untymage untymage
17

Make the slug optional but redirect user to slugged url

Just real quick: If we hit this url : https://stackoverflow.com/questions/5...
Laravel
17
143
danultimate danultimate
15

getting undefined index with a post.

I'm trying to fetch some data in a table, GET requests work ok but when I try to add a new column from the form. Testing with postman gives me Undefined index: prov...
Requests
15
141
hakhsin hakhsin
15

Get CSRF token mismatch when trying destroy a token

Hi, When I try to destroy a token I get "Get CSRF token mismatch" error. How should I solve it? I know the reason is CSRF token. My app is restFul api....
Laravel
15
107
van-india van-india
14

how to pass url with id in laravel js file

i have js file link in laravel blade file so how to pass id in url i m using datatable js file so how can i pass id in url here is my datatable.js file...
Laravel
14
88
luisalmeida luisalmeida
14

Auto increment ID for each client of the user

I've been thinking the following scenario. On mey proejct I have USERS and each users may have multiple clients registered on the platform. So I have a clients table...
Laravel
14
131
tomasosho tomasosho
14

"404 Not Found" when submitting subscription form

My Subscription controller <?php namespace App\Http\Controllers; use Illuminate\Http\Request; use App\Plan; class SubscriptionController extends Contro...
Laravel
14
197
Neeraj1005 Neeraj1005
14

Request handler action

In this tree view sidebar, how can I perform the handler action? <li class="nav-item has-treeview"> <a href="#&...
Laravel
14
493
van-india van-india
14

how to display dynamic data in datatable ?

how to display dynamic data in datatable here is my controller code public function json_view() { $view = Pg::all(); return respon...
Laravel
14
124
gr_bl gr_bl
14

CRUD update with random entries

I have table with X and Y coordinates and time. Is it possible to update them with random value? Something like coordinate between 40 and 45 degrees and random time in last...
General
14
92
Create a New Discussion Button