blank screen appear after uploading picture
<p>I am trying uploading picture using ci.  Yet after I am doing the picture processing blank screen appearing.</p>

<p>I am trying to upload 660 KB picture.</p>

<p>controllers/Cuploadfile.php</p>

<pre><code> //file upload function
function uploadgallerypic()
{
    //set preferences
    $config['upload_path'] = './uploads/';
    $config['allowed_types'] = 'jpg|gif';
    $config['max_size']    = '1000000';

    //load upload class library
    $this-&gt;load-&gt;library('upload', $config);
    $this-&gt;load-&gt;model('Mpages');


    if (!$this-&gt;upload-&gt;do_upload('filename'))
    {
        // case - failure
        $upload_error = array('error' =&gt; $this-&gt;upload-&gt;display_errors());
        $this-&gt;load-&gt;view('addpicture', $upload_error);
    }
    else
    {
        // case - success
        $gallery_id = $this-&gt;uri-&gt;segment(3);

        $upload_data = $this-&gt;upload-&gt;data();
        $filename = $upload_data['file_name'];
        $this-&gt;Mpages-&gt;add_picture_gallery($filename, $gallery_id);

        $data['success_msg'] = '&lt;div class="alert alert-success text-center"&gt;Your file &lt;strong&gt;' . $upload_data['file_name'] . '&lt;/strong&gt; was successfully uploaded!&lt;/div&gt;';
        $this-&gt;load-&gt;view('addpicture', $data);
    }
}
</code></pre>

<p>views\addpicture.php</p>

<pre><code> &lt;div class="col-md-6 col-md-offset-3 well"&gt;
    &lt;br&gt;

    &lt;?php $gallery_id = $this-&gt;uri-&gt;segment(3); ?&gt;
    &lt;?php echo form_open_multipart('Cuploadfile/uploadgallerypic/'.$gallery_id);?&gt;

    &lt;label&gt;&lt;b&gt;UPLOAD PICTURE&lt;/b&gt;&lt;/label&gt;&lt;br&gt;&lt;br&gt;

    &lt;div style="margin-left: 35px"&gt;
    &lt;fieldset&gt;
        &lt;div class="form-group"&gt;
            &lt;div class="row"&gt;
                &lt;div class="col-md-12"&gt;
                    &lt;label for="filename" class="control-label"&gt;Select File to Upload&lt;/label&gt; 
                &lt;/div&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class="form-group"&gt;
            &lt;div class="row"&gt;
                &lt;div class="col-md-12"&gt;
                    &lt;input type="file" name="filename" size="20" /&gt;
                    &lt;span class="text-danger"&gt;&lt;?php if (isset($error)) { echo $error; } ?&gt;&lt;/span&gt;
                &lt;/div&gt;
            &lt;/div&gt;
        &lt;/div&gt;

        &lt;div class="form-group"&gt;
            &lt;div class="row"&gt;
                &lt;div class="col-md-12"&gt;
                    &lt;input type="submit" class="edit" value="Upload File" class="btn btn-primary"/&gt;
                &lt;/div&gt;
            &lt;/div&gt;
        &lt;/div&gt;
    &lt;/fieldset&gt;
    &lt;/div&gt;  
</code></pre>

<p>I wonder why the blank screen appearing after I upload my slideshow picture?</p>