QloApps Forums
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    INTERIOR IMAGE NOT WORK

    Bug Report
    interior image
    5
    13
    2627
    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.
    • Faiz
      Faiz last edited by

      I tried to upload the sample image you have sent in the interior block of QloApps demo.
      The picture got uploaded successfully and also got displayed at the front.
      Please refer to these screenshots.
      https://prnt.sc/l3wuds
      https://prnt.sc/l3wupe

      1 Reply Last reply Reply Quote 0
      • L
        lethach last edited by

        I don't know why! I save as picture as png type and upload ok. On my computer (localhost) i can't upload jpg file.
        Thanks for helping.

        1 Reply Last reply Reply Quote 0
        • Faiz
          Faiz last edited by

          As we are checking, the jpg files are uploading properly and also displaying at the front.
          So there is no issue from our end.
          As you have installed QloApps on your localhost we cannot check the issue at your end also.
          So we recommend you to install QloApps on a public server and provide your FTP details on our ticket system. This way we will be able to check the issue at your end.
          Please raise a ticket here: https://webkul.uvdesk.com/en/customer/create-ticket/

          1 Reply Last reply Reply Quote 0
          • D
            duongledong4 last edited by

            Hi @lethach
            I tried for this, it works fine, but if your images are so big memory then you have to decrease memory to several hundred kb before updating

            1 Reply Last reply Reply Quote 1
            • U
              UnTamed1 last edited by

              Need to edit file AdminAboutHotelBlockSettingController.php
              strtolower needed for preg match.

              Under function processSave()

                  if (!(Tools::getValue("id_interior_image") && !$file['size'])) {
                      if (!$file['size']) {
                          $this->errors[] = Tools::displayError($this->l('Gallery Image Required.'));
                      } elseif ($file['error']) {
                          $this->errors[] = Tools::displayError($this->l('Cannot upload file.'));
                      } elseif (!(preg_match('/\.(jpe?g|gif|png)$/', strtolower($file['name']))
                          && ImageManager::isRealImage($file['tmp_name'], $file['type']))
                      ) {
                          $this->errors[] = Tools::displayError($this->l('Please upload image file.'));
                      }
              
              U 1 Reply Last reply Reply Quote 0
              • U
                UnTamed1 @UnTamed1 last edited by

                @untamed1 said in INTERIOR IMAGE NOT WORK:

                Need to edit file AdminAboutHotelBlockSettingController.php
                strtolower needed for preg match.

                Under function processSave()

                    if (!(Tools::getValue("id_interior_image") && !$file['size'])) {
                        if (!$file['size']) {
                            $this->errors[] = Tools::displayError($this->l('Gallery Image Required.'));
                        } elseif ($file['error']) {
                            $this->errors[] = Tools::displayError($this->l('Cannot upload file.'));
                        } elseif (!(preg_match('/\.(jpe?g|gif|png)$/', strtolower($file['name']))
                            && ImageManager::isRealImage($file['tmp_name'], $file['type']))
                        ) {
                            $this->errors[] = Tools::displayError($this->l('Please upload image file.'));
                        }
                

                Other option is to change preg_match string to '/.(jpe?g|gif|png)$/i'

                Faiz 1 Reply Last reply Reply Quote 1
                • D
                  duongledong4 last edited by duongledong4

                  Hi @Faiz ,
                  I can not upload the file about more than 2.5 Mb. Beacause the clear image is very important for introduce my hotel, so i want to keep the original images? Is it possible with this size image or?

                  Thank you

                  1 Reply Last reply Reply Quote 0
                  • Faiz
                    Faiz @UnTamed1 last edited by

                    @untamed1 Thanks for bringing this into our notice. We really appreciate that.
                    We have taken this issue in our top priorities and will resolve this soon.
                    Kudos!!!

                    U 1 Reply Last reply Reply Quote 0
                    • U
                      UnTamed1 @Faiz last edited by

                      @faiz No problem, glad to help.

                      1 Reply Last reply Reply Quote 0
                      • S
                        Sumit Global Moderator last edited by

                        @duongledong4
                        Please set max_upload_filesize and post_max_size values on your server to the value more than the size of image you want to upload.
                        Please set 16M to both the variables once and then upload the image.

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