Category "laravel-8"

How to perform action globally when record get updated in laravel

Is that possible to run this job UpdateRateZone globally wheneven Consignment Model gets updated anywhere in the system? One method is to use Observer but obser

find_in_set with join table in laravel

User table id - name - b_id 1 - San - 1,1 2 - Kar - 1,2 3 - Das - 1,3 Books table id - book_name - book_author 1 - JAVA - jim 2 - PHP - json 3 - LARAVEL - rax

Laravel Horizon internal server error on 'horizon/api/*'

I tried to implement Horizon, from the terminal when I run commands like php artisan horizon:status or php artisan horizon:list I get positive feedbacks, everyt

Laravel Model is freezing the server. Timeout error

I'm having a really strange issue here. I have a user model (detailed below). It all works fine until I added the getReportsSharedAttribute function. When this

Unable to update user role spite package when datatype changed to UUID

Hi I am using Spaite package for roles and permissions. I am using UUID datatype. Everything works fine when used normal integer datatype. Now showing Following

My coding mistake or problem with the integrity of the data?

I'm learning Laravel from Laracasts videos and so far I've made simple blog with 4 posts that are dynamic but only 2 of them when I click on the name of the pos

Install an Older Version of Laravel with Sail

I have a server that is still running PHP 7.4.x I, therefore, need to install laravel 8.x (the current version of laravel is 9.x) with laravel-sail. Since I don

Text blur on print laravel invoice package which is based on DOMPDF

Hi I have created a pdf with Laravel invoice package now the pdf showing in the display is fine but when printing that document fonts get blurred anyone please

Laravel custom validator returns page instead of json

I made a controller to store tasks, it looks like: public function store(StoreTaskRequest $request) { $validated = $request->validated();

How to check authorization before loading Route Model Binding

I ask this question after doing various searches without finding any clarifying information that helps me solve the problem that I am presenting. I have created

I get this error: Attempt to read property "Username" on null, when trying to display the username [duplicate]

I am trying to display the Username on the web page, but I keep on getting the error Here is my blade template @extends('layouts.app') @secti

How to handle if <![CDATA[ ]]> is null/empty?

I want to convert xml data into JOSN format but there is an issue if I try to do that. simplexml_load_string() returns empty data once after it perhaps get <

The DELETE method is not supported for this route. Supported methods: GET, HEAD, POST in laravel 8

I get the following error with the code below. The DELETE method is not supported for this route. Supported methods: GET, HEAD, POST Controller public functio

Hide button before enter valid data, unhide it after enter valid data

{{ Form::label('name', __('Task name***'), ['class' => 'form-control-label']) }} {{ Form::text('name', null, ['class' => 'form-con

What causes the "route not defined" error in this Laravel 8 API?

I am working on a registration form with Laravel 8 and Angular 13. The back-end is an API (link to Github repo). In the UserController I have a signin() and a s

how to use @foreach inside AJAX & jQuery code for insert Multiple rows Data in Laravel 8

The code it works normal when i put option in static mode, for example: "<select name='id_post[]' id='' class='form-control'>"+ "<option value='1'&

SQLSTATE [42000]: Syntax error or access violation

Grouping without disabling strict mode of MySQL, the following query works if I disable strict mode, however, I would like not to do it, someone could give me a

http to https and www to non-www not working correct with laravel 8 URI links

I searched a lot of about this topic to redirect all urls to https://my-domain I want delete the www and add https. I found a lot of answers this one work good

Laravel - Method Illuminate\\Support\\Collection::makeHidden does not exist

I want to hide the columns password & OTP ,that is included in $uses result. Actually these 2 columns are part of the users table. I've tried like below. B

how to send error emails to the developer in laravel 8 App

I am using laravel "laravel/framework": "^8.75" version. When deployed the app turn APP_DEBUG=false but users get errors but they can not know what is wrong and