skip to Main Content

Jquery – Laravel 11 Cors issue

I've configured my laravel 11 application to handle cors using the following cors.php file in the config dir <?php return [ 'paths' => ['*'], 'allowed_methods' => ['GET, POST, PUT, OPTIONS'], 'allowed_origins' => ['http://localhost:8082'], 'allowed_origins_patterns' => [], 'allowed_headers' => ['Origin, Content-Type,…

VIEW QUESTION

Laravel – How to filter one collection with data from other collection?

On laravel I have 2 requests : $interviewers = Interviewer::get()->pluck('name', 'id'); $defaultInterviewers = UserMeetingInterviewer::getUserMeetingId($this->record->id)->get()->pluck('id'); How to leave in $interviewers only values which exists in $defaultInterviewers ? Sure I know how use foreach with new var, I mean methods from https://laravel.com/docs/10.x/helpers...…

VIEW QUESTION

Laravel private file serving pending problem

I save some photos privately in the storage and show them to the user when needed using the following method. in route : Route::get('/serveFile/{address?}', [FileController::class, 'serveFile']) ->where('address', '.*')->name('serveFile'); in controller : public function serveFile($address = null) { return response()->file(storage_path($address)); }…

VIEW QUESTION
Back To Top
Search