Browse AI Field GuideForum Podcast
All ThreadsLeaderboard
  1. Discussions

    1. Popular This Week
    2. Popular All Time
    3. Solved
    4. Unsolved
    5. No Replies Yet

Marcolino922's avatar

How does it work addMinutes?

Hi, I wanted to ask for more information to those who know more. In Laravel 7, what should be the function of addMinutes? Is it possible to set it to upload images? Are they automatically deleted from the database? Thanks for the sure clarification.

Marcolino922's avatar
Marcolino922's avatar Snapey5yrs agoGeneral
7
5
Last reply by Snapey 5yrs ago
Jecs9's avatar

putFileAs completing but not saving file into my disk/folder

I have been trying to upload images from a form with putFileAs but so far I have not been able to complete the task I have read that I need to use enctype="multipart/form-data" in the form and I have done it <form method="POST" action="/blog" enctype="multipart/form-data"> @csrf <div class="field"> &l

Jecs9's avatar
Jecs9's avatar Sinnbeck5yrs agoLaravel
3
1
Last reply by Sinnbeck 5yrs ago
varovas's avatar

VueJS mutiple file uploads

Hi, I have a question. Is there any way to upload images one by one? For example, user uses input file to upload multiple images (for example 4 images). And I need to upload them 1 per request.

varovas's avatar
varovas's avatar Talinon5yrs agoVue
4
1
Last reply by Talinon 5yrs ago
shahr's avatar

Dropzone CSRF token mismatch

I am using Dropzone to upload images using Laravel 5. After Dropzone makes the put call to my URL I get the following error: dropzone upload.blade.php <div class="dropzone" id="drop"> </div> header @section('style') <link rel="stylesheet" href="{{ asset('themes/css/dropzone.css') }}"> @endsection script.js <scr

shahr's avatar
shahr's avatar Blerion3yrs agoLaravel
8
1
Last reply by Blerion 3yrs ago
culeaalex's avatar

Delete route not found

Hi. I have made a gallery images upload and now want to make the delete method, but submitting the delete form redirects me to a 404 page. web.php Route::middleware(['auth'])->group(function () { //[.......]// Route::delete('series/{series}/gallery_image/{$image}','Series\SeriesController@deleteGalleryImage')->name('series.gallery_image.destroy'); }); route:list DE

culeaalex's avatar
culeaalex's avatar Snapey6yrs agoLaravel
3
1
Last reply by Snapey 6yrs ago
SarahS's avatar

Updating a BelongsTo table

I have two tables - Animals and AnimalPhotos. I want to upload images and store them in the AnimalPhotos table. There is a One-to-Many relationship between the tables. My AnimalPhotoController.php store method looks like this: public function store(Request $request) { $attributes = request()->validate([ 'name' => 'required|image|mimes:jp

SarahS's avatar
SarahS's avatar SarahS746yrs agoLaravel
2
1
Last reply by SarahS74 6yrs ago
LaraBABA's avatar

Laravel 6 Validator issue with multiple files(images and documents)

Hi all, I have a project here the requires the user to upload any of the below types in a single upload file: pdf,jpeg,png,xlsx,doc,docx The file is being sent from an axios post and receive as base64. When I use this rule and only upload images the validation works: $validator = Validator::make($request->all(), [ 'file' => 'image|mimes:jpeg,png,jpg|ma

LaraBABA's avatar
LaraBABA's avatar Boubou6yrs agoLaravel
2
1
Last reply by Boubou 6yrs ago
Pixelairport's avatar

Change request via trait in model

Hi. I i build an extension to upload images, to use it in different other extensions. I think about using a trait which uses the boot methods to do all upload stuff and then replace the request. This is the problem... how can i replace the request. In my example i have an image called "main_image" and want to do something like that: trait UploadTrait { public static f

Pixelairport's avatar
Pixelairport's avatar Pixelairpo...6yrs agoRequests
2
1
Last reply by Pixelairport 6yrs ago
Drewlim7's avatar

Controller received empty data using AJAX and dropzone.js

Hi I am using dropzone.js to upload images together with existing formdata. I managed to combine both of them and using ajax to post if dropzone is empty. However, when I uploaded an image and send it to my controller with the existing form data, and i used dd($request->all()); to output the data but all I received was an empty array []. I even dd $request and I realised fi

Drewlim7's avatar
Drewlim7's avatar Drewlim76yrs agoLaravel
1
1
Last reply by Drewlim7 6yrs ago
pandiyan's avatar

laravel mkdir

Hi ,i need to upload images in my project ,so i use this mkdir("/images') code for create folder, but i don't know where the folder is created in my project. i need to know that images folder location

pandiyan's avatar
pandiyan's avatar boyjarv3yrs agoLaravel
4
1
Last reply by boyjarv 3yrs ago
nanadjei2's avatar

Controller won't return response after job successfully runs

I have a job in my controller which I am using to upload images. When I test with Insomnia or Postman I get my success response but when am testing with my front-end react application I don't receive any response. This is my controller method: public function store() { request()->validate(['property_id' => 'required|integer', 'images' => 'required|array', 'image

nanadjei2's avatar
nanadjei2's avatar Ap3twe6yrs agoLaravel
22
1
Last reply by Ap3twe 6yrs ago
bionary's avatar

Paid Membership App Advice

I need to build a web app for paying members. I'm looking for some general advice on what packages / services I should use to do so. **If you have recommendations from direct experience with the required packages / services please leave me some feedback here. **Thank you. The web app should be able to do/have this: Video Library Live Chat Forum Membership (paid) Managed ser

bionary's avatar
bionary's avatar bionary6yrs agoGeneral
0
1
itsjoshbruce's avatar

Laravel 6 (upgrade from 5.8) Failing to Find Route and 404 Page

I'm getting ready to delve into deeper pages for my site. Created route group (practitioners). Created home page URL (get). Created profile page route (get). Went from link on homepage to profile page, the following happened. (Can't upload images, sorry.) The routes. The route list: It's a monorepo with four sites, in case that matters. The error. Anybody seen something li

itsjoshbruce's avatar
itsjoshbruce's avatar amidknight6yrs agoLaravel
6
1
Last reply by amidknight 6yrs ago
vivification's avatar

Data Tables are not loading - maybe Javascript error?

I am not sure if this is a Laravel or Javascript issue, but I need help trying to get my Data Tables to work. I think it's JavaScript, but the GitHub documentation is not available as the website isn't working - so I can't work out how to solve this. Could someone please help? I have followed the instructions from https://github.com/yajra/laravel-datatables/issues and also a vi

vivification's avatar
vivification's avatar tykus6yrs agoLaravel
1
19
Last reply by tykus 6yrs ago
Amsel's avatar

Nova form on the frontend?

I want to give users the ability to fill some forms on the frontend, is there any way to reuse the forms in Nova and use them outside the admin panel? Or should I create a completely new form on the frontend? I want non-users to fill a couple of forms, and Nova has some great ways to upload images and add other resources, but I may have to redo that part. Thoughts?

Amsel's avatar
Amsel's avatar Amsel7yrs agoNova
0
1
AleksXiao's avatar

position.coords.latitude not working

can someone help this is my code @extends('layouts.appOwner') @section('content') <div class="bannerReg"> <label for="X" class="col-sm-4 col-form-label text-md-right">{{ __('Location X') }}</label> <img style="margin-top:17px;margin-left:10px;margin-rigt:10px;float:left; height: 7%; width: 9.3%;&

AleksXiao's avatar
AleksXiao's avatar ftiersch7yrs agoLaravel
1
1
Last reply by ftiersch 7yrs ago
fredemagi's avatar

How to set folder permissions for public users' folder?

I'm making an app where people can sign up, edit their user's profile etc. When people I sign up, I make a new folder for their images like this: Storage::disk('public')->makeDirectory('user-images/'.$external_id); user-images is located in storage/app/public. A symbolic link connects the path with public/storage. However, when new users signs up, either the new folder is c

fredemagi's avatar
fredemagi's avatar DevMaster7yrs agoForge
3
1
Last reply by DevMaster 7yrs ago
mDelshad's avatar

how to access a file in the local disk?

i'm upload images with this code: $path = $request->file('image')->store('documents'); and i can get file address with return $path but when i open the link in browser, error 404 displayed The image is uploaded correctly! I also executed this command php artisan storage:link in public folder and this directory storage just avatar folder has been created , But the folder

mDelshad's avatar
mDelshad's avatar Snapey7yrs agoLaravel
4
1
Last reply by Snapey 7yrs ago
SiNi_Si's avatar

Uploading files to public storage simlink

I'm using ajax to upload images to summernote, and all works fine to the public image directory using... $image->move(public_path('images/users/'.$id.''), $new_name); what do I need to change this to, to send this to my simlink storage directory? I have checked and ran... php artisan storage:link and it does return... The "public/storage" directory already exists.

SiNi_Si's avatar
SiNi_Si's avatar SiNi_Si7yrs agoEnvoyer
6
1
Last reply by SiNi_Si 7yrs ago
nero's avatar

How to apply the translation in the .js script

I created a page to upload images. I use javascript to enhance the appearance. I want to apply the language translation to the CHANGE button in the xxx.js. script. If the html tag is in the blade as usual I use the {{trans ('global.CHANGE')}} pattern. But how do you write if the CHANGE button code is at xxx.js? How do I write in the javascript code in the xxx.js file? the follo

nero's avatar
nero's avatar Reached7yrs agoLaravel
1
1
Last reply by Reached 7yrs ago
Nikki's avatar

Getting a image preview to be removed from list

I'm trying to have a page that when you upload images it shows a preview of it and if you want you can remove it from the list. I have the preview working and all that but I can't get the remove button to work. I'm using Vue and laravel I also get this error Error in render: "TypeError: _vm.files[index] is undefined" <template> <!-- isDragging = if(isDr

Nikki's avatar
Nikki's avatar signar7yrs agoVue
5
1
Last reply by signar 7yrs ago
technodiva's avatar

Post location - Voting system

Hello, I'm working on this app for users who can upload images, and users to vote on them. I've done the part about creating content and showing it, now I'm at the stage to build the voting system. Request: Post has 2 buttons: Black vote & White vote Press button: • +1 added in db • one time per user • one button or the other, not both • user can unvote Post can be either i

technodiva's avatar
technodiva's avatar aurawindsu...7yrs agoLaravel
1
1
Last reply by aurawindsurfing 7yrs ago
techtailor's avatar

Uploading Video Files in Background

Hey fellas, So i got an app where a user can upload image/video files upto 100mb which I am storing on S3, however my current setup doesn't seem ideal as the user has to wait after uploading the file for it to be uploaded to S3. Whats the best way I can do that in the background? Like once the uploading finishes the user is redirected to a processing page and the system in the

techtailor's avatar
techtailor's avatar martinbean4yrs agoLaravel
4
1
Last reply by martinbean 4yrs ago
humblecoder's avatar

How do I move files between folders in Digital Ocean Spaces?

I can upload images to DO Spaces and view them (both in-app and via public URL) just fine. However, when I attempt to use Storage::move($old_path, $new_path) I receive a 404 Not Found and aNoSuchKey error. The URL being processed looks thusly: https://myappname.nyc3.digitaloceanspaces.com/my_bucket?prefix=photos%2Ffolder%2F2f19fe78-bf49-4393-beef-c51c7b34c119%2FB4CB6004044A42

humblecoder's avatar
humblecoder's avatar promatik6yrs agoLaravel
1
1
Last reply by promatik 6yrs ago
NOMGUY's avatar

multiple image uploading

What to write in Form::file so that I can upload multiple images. {!! Form::open(['method' => 'POST','route' => 'albums.store','files'=>true]) !!} <div class="container"> <div class="card"> <div class="card-header"> <h3>Create an Album</h3>

NOMGUY's avatar
NOMGUY's avatar saurabhd7yrs agoLaravel
2
1
Last reply by saurabhd 7yrs ago
siradam's avatar

Call an api class through app

I am currently trying to use Uploadcare as a service for my website to help me to upload images. I am very new to Laravel and have am stuck on a single instruction. Following the instructions below, I do not understand by what is meant when he says, "Call the Uploadcare\Api class through app()->Uploadcare? Can someone please clarify. Clicking on the link of Uploadcare\A

siradam's avatar
siradam's avatar Robstar7yrs agoLaravel
6
1
Last reply by Robstar 7yrs ago
Msoft's avatar

how to fix Call to a member function getClientOriginalExtension() on null in laravel 5.6

in my laravel application I am using dropzone programmatically to upload images. this is my Controller to store images in VehicleController public function store(Request $request) { $photos = $request->file('file'); if (!is_array($photos)) { $photos = [$photos]; } if (!is_dir($this->photos_path)) { mkdir($this-&g

Msoft's avatar
Msoft's avatar rivory_g7yrs agoLaravel
11
1
Last reply by rivory_g 7yrs ago
teguh_rijanandi's avatar

Call to a member function getClientOriginalName() on null

i am try to upload images, but my project was show this error code Call to a member function getClientOriginalName() on null and then highlighted on $file = $request->file('gambar'); $fileName = $file->getClientOriginalName(); $request->file('gambar')->move("image/", $fileName); note: gambar is image (Indoensian Language)

teguh_rijanandi's avatar
teguh_rijanandi's avatar Cronix7yrs agoLaravel
1
1
Last reply by Cronix 7yrs ago
agilasadi's avatar

Implementing summernote and uploading image issue

I'm trying to upload images withing the summernote, the problem is, when i return the filename after upload, i can not insert it in the editor, like it does return the name, i can output it in console but does not add up to the rest of path. here is the code $('#texteditor').summernote({ height: 400, callbacks: { onImageUpload: function(file, edi

agilasadi's avatar
agilasadi's avatar neilstee7yrs agoJavaScript
1
1
Last reply by neilstee 7yrs ago
Moenchfracht's avatar

Storage and retrieving files

Hi, I am using subdomains for my users eg. username.domain.com. Users can upload images to their own storagedisks. in config\filesystems.php I have: 'user' => [ 'driver' => 'local', 'root' => NULL, 'visibility' => 'public' ], and my testfile (which should only display the image): config(['filesystems.di

Moenchfracht's avatar
Moenchfracht's avatar 368647yrs agoLaravel
13
1
Last reply by 36864 7yrs ago
dgoetz's avatar

How to insert array of data into single table?

Hello, I am currently trying to upload images to my application through a form, but want to allow the ability to upload multiple images for each "event". Here is my controller code: $event = Event::create(request(['name', 'location', 'address', 'dateAndTime', 'shortDescription', 'longDescription'])); $images[] = request('imageName'); foreach($images

dgoetz's avatar
dgoetz's avatar Vilfago8yrs agoLaravel
7
1
Last reply by Vilfago 8yrs ago
virgiltu's avatar

How to set one picture to default ?

I have been trying to figure this out for about a day and a half now. I am trying to upload images with something like dropzone js, as it seems to be working well with vue. However how can I set one of the images as default? I would like to be able to press on one of them and set it as default. Lets say that I upload 5 images but only one need to be default. Also i am loading a

virgiltu's avatar
virgiltu's avatar Waseem8yrs agoVue
1
1
Last reply by Waseem 8yrs ago
mikail10000000's avatar

Laragon, laravel symbolyc link does not work

Hi, I'm using laravel with laragon, everything works fine exept that when I upload images they return 404 , and public/storage is empty however storage/app/public has the files , also public/public has the files , so it creates a wrong folder public inside the public folder, I did run the php artisan storage:link command , how can I get it work? I guess it's laragon's issue co

mikail10000000's avatar
mikail10000000's avatar mikail1000...8yrs agoLaravel
0
1
michael1986's avatar

Intervention image orientation taken by iPhone

Hi all, For my project I need to upload images using an iPhone. This will be done in portrait mode, using a vue component which actually shows the image in portrait mode. The component creates a base64 version of the image which will be posted. So far so good. On the Laravel side, this is a part of the function so far: // Strip the first part of the base64 value. $image = explo

michael1986's avatar
michael1986's avatar blyleven8yrs agoLaravel
3
1
Last reply by blyleven 8yrs ago
naspy971's avatar

Bootstrap navbar messed up in Laravel 5.6

Hi, that's kind of weird but my subject was originally on stackoverflow and just realised the best idea would have been laracasts so here's the subject : https://stackoverflow.com/questions/48951572/bootstrap-navbar-messed-up-in-laravel-5-6 Also we can't upload images and format code in this forum which is pretty annoying in my opinion. Well, I must add onto the subject that bo

naspy971's avatar
naspy971's avatar naspy9718yrs agoLaravel
6
1
Last reply by naspy971 8yrs ago
uchihaabhi's avatar

Image directory path retrieval using Laravel RESTapi

I am developing RESTful apis using laravel. My question is that I can upload images but unable to return the full storage directory which will be used in an android app. Can anybody help me out?

uchihaabhi's avatar
uchihaabhi's avatar uchihaabhi8yrs agoLaravel
0
1
Kistlak's avatar

How To Solve This Image Insert

I'm creating a web site. And I have created a registration page. When I insert data, all the data successfully inserted into the database. But, images didn't insert into the database and not moved to the folder. How can I Fix this ?? Here is the AdminPanel.blade.php <div class="panel-body"> @if(session()->has('Msg')) <h4 class="alert alert-succes

Kistlak's avatar
Kistlak's avatar Kistlak8yrs agoLaravel
3
1
Last reply by Kistlak 8yrs ago
mattnewark's avatar

Uploading image to the storage folder

Hi Guys, I am trying to upload images to the storage folder that is located above the public_html folder on my server so that I am able to hide my .env file etc. So what I am doing is creating the directory in the storage folder which is working fine: if(!Storage::exists("/public/images/$userName")) { Storage::makeDirectory("/public/images/$us

mattnewark's avatar
mattnewark's avatar mattnewark8yrs agoLaravel
9
1
Last reply by mattnewark 8yrs ago
Firemaps's avatar

Failed to load resource: the server responded with a status of 500 (HTTP/2.0 500)

On my site I am trying to upload images and extract information from the exif, including GPS tag etc. On laptop, there is no problem. However on mobile, with the same images, I am getting "Failed to load resource: the server responded with a status of 500 (HTTP/2.0 500)" How can I debug this? Or is there something else I can install? This suggests https://www.digitalo

Firemaps's avatar
Firemaps's avatar ejdelmonic...8yrs agoServers
4
1
Last reply by ejdelmonico 8yrs ago
mathishuettl's avatar

MimeTypeGuesser -> FileNotFoundException

Hello, I have a strange problem on a project. There is a file-upload function where users can upload images and videos. Sometimes this problem appears and sometimes it doesn't. It's only when the user uploads a video. that is greater then about 2 mb https://imgur.com/lNRGIkC public function upload(Request $request) { $rules = [ "tags" => "requi

mathishuettl's avatar
mathishuettl's avatar mathishuet...8yrs agoLaravel
1
1
Last reply by mathishuettl 8yrs ago
Knaggsy's avatar

New Laravel Old Symfony 2 broken.

Until recently I used an application that pulled data from WordPress MySQL tables to a single page web app on a Symfony2. Due to an hacked server that crashed my setup and with the upgrade to PHP7 that created a large amount of bugs using Symfony2 I have decided to look at Laravel. I would appreciate any help and advice on the feasibility of using Laravel for this product. The

Knaggsy's avatar
Knaggsy's avatar Knaggsy8yrs agoLaravel
0
1
Firemaps's avatar

Errors after composer update in production

Lesson learnt, don't run composer update in production. I ran composer update in production and encountered some errors. I was not able to log into my site. Getting error "UnexpectedValueException The stream or file "/home/forge/mysite.com/storage/logs/laravel.log" could not be opened: failed to open stream: Permission denied" I was able to enable log in wit

Firemaps's avatar
Firemaps's avatar Screenbeet...8yrs agoForge
2
1
Last reply by Screenbeetle 8yrs ago
engamr's avatar

No 'Access-Control-Allow-Origin' with laravel and angular js - not normal case

Hi I develop application and use this technology I used Angular js for frontend application and for backend i used laravel 5.2, I already install cors origin allowed in my project because all data transfer very good, but when I upload images using ajax and base64, then I get this message from my browser: XMLHttpRequest cannot load http://www.api.panakeias.com/updateTeacherpicp

engamr's avatar
engamr's avatar engamr8yrs agoLaravel
0
1
idcreatv's avatar

Storing Signature Pad Base64 using Image Intervention

Hi all, hope someone can help me with a problem I have with Signature Pad. I've dd'd all of this and all is fine until it gets to the Image::make section where I'm getting an internal server error 500. I've used intervention to upload images and store them without any issues but converting into a PNG file is proving a problem and I'm not sure where I'm going wrong. This is my c

idcreatv's avatar
idcreatv's avatar idcreatv8yrs agoGeneral
1
2
Last reply by idcreatv 8yrs ago
Sven0188's avatar

Laravel 5.4 :: Session to hold parent ID's

Good day Everyone, I am curious as to whether it is acceptable practice to store the ID of a 1:m relationship in the session()? For example - I have items and each item have multiple images. This is a 2 step process to create/edit an item and thereafter upload images. So when creating an item I store the item ID in session() then redirect to my images controller method to uploa

Sven0188's avatar
Sven0188's avatar Sven01888yrs agoLaravel
6
1
Last reply by Sven0188 8yrs ago
ThePenguin's avatar

Amazon S3 vs Rackspace Cloud Files (download speed / performance)

Hopefully this should be a simple question: I wish to upload images to either Amazon S3 or Rackspace Cloud Files and serve them on my site. Nothing fancy at all. As for quantity, maybe up to 10,000 files, with say a few million downloads a month. Nowhere near the levels to mandate the cost of a CDN. Based on pricing calculations, I'm looking at... around 10 dollars a month. My

ThePenguin's avatar
ThePenguin's avatar ThePenguin8yrs agoServers
0
1
TheFriendlyHacker's avatar

Can you hide overflow on an <img> tag?

I am allowing users to upload thumbnail images for posts they make. In order to comply with the site's layout, the images have to be about 450px x 225px. Obviously, I wouldn't want to limit users to only being able to upload images with those exact dimensions. And I don't want to just resize the images to those dimensions, because it will distort them. Is it possible to set an

TheFriendlyHacker's avatar
TheFriendlyHacker's avatar tekmi9yrs agoGeneral
1
1
Last reply by tekmi 9yrs ago
samalapsy's avatar

Adding watermark to Image using Image Intervention

Please how can I add watermark to my uploaded image. It's working with the code below. $image = $request->file('banner'); $slug= "bgh-dsd"; $key=0; $fileName = "img-".$slug."-".$key. "." . strtolower($image->getClientOriginalExtension()); $destinationPath = $path; //Upload Images On

samalapsy's avatar
samalapsy's avatar samalapsy9yrs agoLaravel
1
1
Last reply by samalapsy 9yrs ago
Jake2315's avatar

GD Library extension not available with this PHP installation

I'm currently trying to upload images with (Laravel 5.4) intervention. Every time I post: GD Library extension not available with this PHP installation. I've already tried sudo apt-get install php7.0-gd And checked php -i | grep -i gd Which is outputting gd GD Support => enabled GD headers Version => 2.2.3 GD library Version => 2.2.3 gd.jpeg_ignore_warning => 0 =&g

Jake2315's avatar
Jake2315's avatar ndotie3yrs agoPHP
6
1
Last reply by ndotie 3yrs ago
trevburley's avatar

NotReadableException in Decoder.php line 20: Unable to read image from file ().

I've been getting this error for a while now on my IIS webserver and Intervention. Developing locally there is no issue and images upload nicely - all the files are identical and folder permissions are as I would expect them to be on both environments. Bearing in mind this only happens on my IIS server and not my local Apache environment is it safe to assume the code is fine an

trevburley's avatar
trevburley's avatar trevburley9yrs agoLaravel
0
1

Want us to email you occasionally with Laracasts news?

Nine out of ten doctors recommend Laracasts over competing brands. Come inside, see for yourself, and massively level up your development skills in the process.

Learn
BrowseSeriesCreatorSeriesLaravel PathLarabitsPlayground
Discuss
ForumPodcastSupport
Extras
Gift CertificatesApparelFAQiOS AppTerms
Social
X(Twitter)TikTokYoutube

© Laracasts 2026. All rights reserved. Yes, all of them. That means you, Todd.

Proudly hosted with Laravel Forge and DigitalOcean.

Want us to email you occasionally with Laracasts news?

Nine out of ten doctors recommend Laracasts over competing brands. Come inside, see for yourself, and massively level up your development skills in the process.

Learn
BrowseSeriesCreatorSeriesLaravel PathLarabitsPlayground
Discuss
ForumPodcastSupport
Extras
Gift CertificatesApparelFAQiOS AppTerms
Social
X(Twitter)TikTokYoutube

© Laracasts 2026. All rights reserved. Yes, all of them. That means you, Todd.

Proudly hosted with Laravel Forge and DigitalOcean.