title: Your server does not support the GD function required to process this type of image.Ci
body: <p>I had done image upload,resized many times in CI. The same code is working in one page but not working in other page . when i display the error it says" Your server does not support the GD function required to process this type of image."  The code to upload image is ...\</p>
  
  <pre><code> function do_upload() {
  
          $original_path = './uploads/activity_images/original';
          $resized_path = './uploads/activity_images/resized';
          $thumbs_path = './uploads/activity_images/thumb';
          $this-&gt;load-&gt;library('image_lib');
  
          $config = array(
              'allowed_types' =&gt; 'jpg|jpeg|gif|png', //only accept these file types
              'max_size' =&gt; 2048, //2MB max
              'upload_path' =&gt; $original_path //upload directory    
          );
          $this-&gt;load-&gt;library('upload', $config);
          $this-&gt;upload-&gt;do_upload();
          $image_data = $this-&gt;upload-&gt;data(); //upload the image
          $image1 = $image_data['file_name'];
  
          //your desired config for the resize() function
          $config = array(
              'source_image' =&gt; $image_data['full_path'], //path to the uploaded image
              'new_image' =&gt; $resized_path,
              'maintain_ratio' =&gt; true,
              'width' =&gt; 128,
              'height' =&gt; 128
          );
          $this-&gt;image_lib-&gt;initialize($config);
          $this-&gt;image_lib-&gt;resize();
  
          // for the Thumbnail image
          $config = array(
              'source_image' =&gt; $image_data['full_path'],
              'new_image' =&gt; $thumbs_path,
              'maintain_ratio' =&gt; true,
              'width' =&gt; 36,
              'height' =&gt; 36
          );
          //here is the second thumbnail, notice the call for the initialize() function again
          $this-&gt;image_lib-&gt;initialize($config);
  
          $this-&gt;image_lib-&gt;resize();
          //$this-&gt;image_lib-&gt;clear();
         echo  $this-&gt;image_lib-&gt;display_errors();
          var_dump(gd_info());
          die();
          return $image1;
      }
  </code></pre>
  
  <p>What is going on i can't understand..??</p>