Bagisto Forum

    Bagisto

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups

    Changing product images not working, because of cache issues

    General Discussion
    2
    8
    5470
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • W
      wallace last edited by wallace

      Hi all,
      I'm getting crazy... I'm trying to change product images, but in the frontend I still get the old ones because of cache issue.
      I think I've tried everything,

      • unlink storage
      • php artisan storage:link
      • php artisan config:cache
      • php artisan cache:clear
      • php artisan vendor:publish
      • delete browser cache
        but nothing.
        Inspecting my page, I still see the old image here:
        https://weclo.it/cache/medium/product/88/SXuYnsStACsbOjS5rtvSFN2076PuCAUZs9GK4mrG.png

      My environment is:
      Bagisto v1.3.1 running on Apache

      Thank you

      1 Reply Last reply Reply Quote 0
      • V
        Vaishali Agarwal last edited by

        @wallace
        could you provide the URL of the product detail page for which product the image is not getting updated?

        1 Reply Last reply Reply Quote 0
        • W
          wallace last edited by

          The url is:
          https://weclo.it/virtual-private-server
          The issue is in the category page where I have the product list view and not in the single product detail page.

          1 Reply Last reply Reply Quote 0
          • V
            Vaishali Agarwal last edited by

            @wallace do you mean all these images https://prnt.sc/17v5v7o are not updating for all the products that are showing here https://weclo.it/virtual-private-server ??

            1 Reply Last reply Reply Quote 0
            • W
              wallace last edited by

              I've tried to change (at the moment) just the first image (for VPS Gold Linux image), without success.
              Whatever image I try to update in admin page, then in the front-end I still have https://weclo.it/cache/medium/product/88/SXuYnsStACsbOjS5rtvSFN2076PuCAUZs9GK4mrG.png

              1 Reply Last reply Reply Quote 0
              • V
                Vaishali Agarwal last edited by

                @wallace
                please verify first the image you are trying to upload is visible on admin end or not, if this is not visible on backend then might be the image size is large.

                1 Reply Last reply Reply Quote 0
                • W
                  wallace last edited by wallace

                  I confirm the image is visible in admin panel (inspecting it, the path is correct: https://weclo.it/storage/product/88/SXuYnsStACsbOjS5rtvSFN2076PuCAUZs9GK4mrG.png). Notice that the image size I'm trying to upload is also smaller.

                  1 Reply Last reply Reply Quote 0
                  • W
                    wallace last edited by

                    I solved the issue and the problem was not due to the cache but to the forced resizing of the image from rectangular to square (I've found in the medium.php '$width = $height = 280'... why this?)
                    My new picture was a rectangular version of the old version image (square); when the rectangular image was resized to square, it looks like the original one as the difference was just a white background.

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post