Category "laravel"

How do I store files in vue.js?

I want to store image files and video files but the data is showing Blob. The video file and image file displays as soon as uploaded which is cool. Please, I

getting error while enter Command => php artisan route:list

This laravel code is running on my localhost when try to execute any command its throwing below error. please find me a solution why it's throwing such error

Laravel csrf token mismatch for ajax POST Request

I am trying to delete data from database via ajax. HTML: @foreach($a as $lis) //some code <a href="#" class="delteadd" id="{{$lis['id']}}">Delete<

Laravel Excel::store file empty after stored

I uploaded this excel file: myExceldocument.xlsx After uploading I want to store in a folder. I used this method: $uploadedFile = $request->file('files')[0]-

Laravel socialite error 404

I followed this tutorial on how to use socialite -> https://laracasts.com/series/whats-new-in-laravel-5/episodes/9 This is what I've done: Added to my comp

Can you create a new Model instance without saving it to the database

I want to create a whole bunch of instances of a model object in Laravel, then pick the optimal instance and save it to the database. I know that I can create

Laravel You requested 1 items, but there are only 0 items available

I am getting row's column randomly to seed database, using eloquent : $physician = SelectOption::where('select_option_group_id', 1)->pluck('name')->rando

Laravel 9: change table and fields for authentication and login

I have changed the table and the Laravel Breeze fields for authentication to some custom ones. It looks fine but in AuthenticatedSessionController.php while I g

Sentry + Laravel: how to log an already catched Exception?

We're using Laravel ( 5.x to 7.x ) in a lot of project and all integrated with Sentry. In some edge case we need to catch some recoverable exceptions to allow p

Querying only one row from a one to many relationship laravel

I have a products table and a product_pictures table, where a single product can have many pictures (one to many relationship). I am trying to display all of th

How to convert binary string to normal string in php

Description of the problem I am trying to import email content into a database table. Sometimes, I get an SQL error while inserting a message. I found that it f

Querying only one row from a one to many relationship laravel

I have a products table and a product_pictures table, where a single product can have many pictures (one to many relationship). I am trying to display all of th

Display Link Title Instead of URL in XSL

I'm learning XSL-as-I-Go, but I'm stuck. My function : public function SitemapHTML() { $xp = new XsltProcessor(); $xsl = new DomDoc

Laravel 5 controller sending JSON integer as string

On my development server the JSON response from the Laravel 5 controller shows the data in the correct types. e.g imdb_rating: 7.6 imdb_votes: 6271 But on t

Create tags in laravel post publishing

Currently when I want to add tags in my posts I have to go to my tags page and create them then go to my post create page and add them to my post by multiple in

How to use Tailwind CSS together with SCSS in Laravel/Vue project?

I'm trying to install tailwind css from this guide into an existing laravel/vue project, which uses scss. install packages yarn add -D tailwindcss@latest postcs

Laravel 5 session not persisting after user is logged in

I'm having an interesting issue with Laravel 5. After logging in a user, the logged in status is not persisted across pages. Clearly it has something to do wit

Decode integrity token using Google PlayIntegrity API

I am trying to implement PlayIntegrity API to my Android app, but I don't know how to decrypt and verify the token using Google's servers. I followed the docume

How to return database table name in Laravel

Is there a way that I can get the current database table in use by the model that I'm in? I see that there is a table() function in Laravel/Database/Eloquent/mo

Convert date and time to Jalali in Laravel

I want to change the time and date calendar to Jalali (Shamsi calendar used in Iran) in my system. How can I do this? "language_title" => "English",