SmokeTM SmokeTM
3

this->authorized always shows 403 page

I think I have set up everything correctly but it always gives me a 403 page and I dont know why. // In Controller $this->authorize('create', auth()->u...
kushal kushal
2

Activity Log - Medicine Management System

I'm developing a medicine management system I have done all my features but one of the features I would like is an activity log where the admin can have that tracebeility...
igaster igaster
8

Laravel 5.4 change login url

Hi! When the auth middleware fails, the user is redirected to the \login url. How can we change this default url to something else?...
Laravel
8
2298
kushal kushal
4

Does not let me migrate my table for activity log it say's PDOException::("SQLSTATE[42000]: Syntax error or access violation: 1103 Incorrect table name ''") #671

migration public function up() { Schema::connection(config('activitylog.database_connection'))->create(config('activity_log.table_name'), function (Bl...
WallyJ WallyJ
1

Stripe - Cashier, or No Cashier

I am getting ready to add Stripe to a project for the first time. My understanding is that I can use Laravel Cashier for this, but I have seen where others skip Cashier and...
cupcakedream cupcakedream
10

Can't Get Attribute Of Related Model

Hey All - I'm running Laravel 6.2 and am getting an error trying to get any attribute of a model through a "belongsTo" relationship. I'm using a "hasmanythro...
Laravel
10
52
NumanArshad NumanArshad
1

post default data in heroku postgresql

I deployed my laravel project on heroku and use postgresql for heroku but there is a table name 'days' that store default value in it .How can I store default values in thi...
sufian sufian
8

Problem with redirect()->intended() after login in Laravel 5.8

I want to redirect user to previous URL after login to the website. This was working fine until i used MustVerifyEmail trait on User Model. After that it always redirect us...
Laravel
8
236
megaman megaman
1

Problem with Maatwebsite / Laravel-Excel

I am trying to use Maatwebsite/Laravel-Excel to generate spreadsheets. my code works locally However when i run it on the test server i get this error Interfa...
afoysal afoysal
8

Mcrypt PHP extension required

I am trying to run below project in my localhost. https://i.stack.imgur.com/H...
lavina lavina
5

The results of a failed request

Hello, i am setting up my requests separately from my controller. When i click a post button all my data is sent over, if it fails, it refreshes page, but i h...
bbmrw bbmrw
6

How to handle user likes another user logic in Laravel?

I would like to build 'likes' functionality in my app where one user (user1) can like another user (user2), and then if user2 likes back user1 they would match. What is the...
mostafalaravel mostafalaravel
9

Laravel Excel : how to export only some columns ?

Hello : I would like to export only some columns (email) : the column email does not exists in table , but it's an accessor !(impossible to say...
noblemfd noblemfd
7

How to Only Display <a> when a field is not NULL

In my Laravel-5.8project, I have a field called manager_employee_goal_comment. The default is NULL I want to only display the when the field is NULL. I applied t...
DeLift DeLift
0

Bug? Validator translation fallback locale can use attribute translations of default locale

I am experiencing a problem using the validator translations and I suspect it's a bug. It has to do with attributes and fallback locales. Validator will retur...
FareedR FareedR
3

How can I count data on secondary foreach ?

Im getting this error "Object of class Illuminate\Database\Eloquent\Collection could not be converted to int" . assume @foreach($stocks as $stock)...

Execute Service Provider after middleware

Hi, I am definning gates in a service provider. However, my gates need data I have to load in a middleware after auth. Specially, my system is a multi-tenant...
Olamilekan Olamilekan
3

Displaying multiple table entries as one

Hello, Good day, Please i have 4 different related tables namely users, accounts, departments, designation. User has 1 to 1 relationship with all tables. i.e a user...
johnef_sh johnef_sh
4

foreach inside foreach and out put first foreach in array

assume I have an array called (data) and inside my array I have a foreach on products I need to get each of this product packages inside this (dat...
sesc360 sesc360
5

How to localize the ModelFactory

Hi all, I implemented a new factory to generate random data. But I want to have this random data in the format of de_DE. So usually I create a faker object first, but this...
Laravel
5
550
alicechan98 alicechan98
1

Delete record by selecting option in dropdownlist with a delete link.

I want to delete a data when select on the dropdown list and click delete button to delete it from database, but whenever is select the option, the last data is deleted but...
JoaoHamerski JoaoHamerski
7

How to mix a helpers JS file that works to all others js files?

So i have a file named helpers.js in resources / js / partials , i tried to mix this file using .js () and .scripts () function, but seems that my other scrip...
Nana-Odai Nana-Odai
10

Sending a welcome email after user verify his account

How to use 'Illuminate\Auth\Events\Verified' to send a welcome email after a user verifies his or her account. EventServiceProvider...
Laravel
10
83
hadis hadis
4

Undefined variable: product_item

I want to update my selection this is my code: productSync.blade: @if( $files && count($files) > 0) <form action="{{ route...
Kartsa Kartsa
2

Pivot model deleted-event not including the id-attribute

I have models Shop, Product and ProductShop pivot table model. I'm using soft deletes and Laravel Auditing to audit all changes. I'm also using a package (ddzobov/laravel-p...
untymage untymage
7

firstOrCreate duplicated entry

I have a table tags which have two records and have unique name column : When i use firstOrCreat...
assadullahch assadullahch
23

Laravel 5.4 is not creating csrf cookie on my hosting

Hello. I have developed a website in Laravel 5.4. It works fine on localhost but when i uploaded on hosting server, it throws this exception TokenMismatchException i...
Laravel
23
701
Seeker1337 Seeker1337
8

Laravel 6+ Upload multiple images through a form

Hello. Basically I have a form that stores some information and an image in a MySql database. However, I have to change this to taking up to multiple images. I've tried loo...
Laravel
8
141
martinbean martinbean
10

Default route parameters?

I’m having an issue with domain-based route groups. I have routes set up like this: Route::domain('{domain}')->group(functio...
Laravel
10
1084
Mahaveer Mahaveer
2

Get user ID By Access Token ?

Without using auth middleware, how to get user id by token? //Get access token $access_token = $request->header('Authorization'); // brea...
greevesh greevesh
2

Running valet (any command) returns: Target class [log] does not exist. In Container.php line 803: Class log does not exist

I have the Linux Valet fork (cpriego/valet-linux) pulled into my composer.json (I've tried it both locally and globally. Whenever I run the command: valet (and any argument...
afoysal afoysal
4

Laravel Structure

Is it a Laravel Project Structure ? https://i.stack.imgur.com/M6D6y.png...
kabelo kabelo
1

CORB error consuming images via api

Hi Has anyone had to deal with CORB before? I have images that I have uploaded to the server. I'm using quasar q-img to consume the images, and the src is the actual...
Synio Synio
0

Laravel Passport Questions

Hi! It's my first post here, but have been watching and reading for a long time. I've created a few nice things with Laravel and right now I'm working on a larger project t...
Create a New Discussion Button