Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

224
Views
How can I store new resize images from stored images in Laravel updating function

I have a Real Estate Directory website in Laravel, where I have stored lot of images around 2000+ records stored.

Now, I'm trying to add new resize images for my mobile device. I want to perform this task on product controller UPDATING FUNCTION. when user click on product update form button without selecting any new images.

From the Previous stored images will resize & store on new location. Previous images contains its dimensions and location. Just add new resize images on clicking updating the product form. Please Help. I'm stuck from 2 days.

$gallery_images_name = PropertyGallery::where('property_id', $id)->pluck('image_name');

    $galcount=0;
    
        foreach($gallery_images_name as $key =>  $gallery_image_name)
        {
            $name = 'property_' . $galcount . time() . '.' . $gallery_image_name;
            $img = Image::make($gallery_image_name->getRealPath());
            $img->resize(124, 182, function ($constraint)
            {
                $constraint->aspectRatio();
            })->save(public_path() . '/upload/m_gallery/' . 'mobile_property_'.$name);
        }
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!