0
public function add_video()
{
    if(isset($_POST['add']) && $_POST['add']=='ADD')
    {

        move_uploaded_file($_FILES['video']['tmp_name'],'uploadimg/'.$_FILES['video']['name']);

        $data = array('id'=>'', 'title'=>$_POST['title'],'video'=>$_FILES['video']['name'],'url'=>$_POST['link'],'status'=>$_POST['status'],'date'=>$_POST['date']);

        $this->Dbfunction->insertdata('videos',$data); 

        redirect(base_url().'index.php/admin/videos');
    }
}

And I Got Following Error

Warning: POST Content-Length of 177938307 bytes exceeds the limit of 8388608 bytes in Unknown on line 0

Database Table Structure is follows

enter image description here

Kunal Waghmare
  • 183
  • 3
  • 10
  • You need to define more than `200M` in php.ini – Mayank Vadiya Nov 29 '16 at 05:00
  • i define 200M in php.ini after that also i got same error – Kunal Waghmare Nov 29 '16 at 05:08
  • 3
    Possible duplicate of [PHP Warning: POST Content-Length of 8978294 bytes exceeds the limit of 8388608 bytes in Unknown on line 0](http://stackoverflow.com/questions/11719495/php-warning-post-content-length-of-8978294-bytes-exceeds-the-limit-of-8388608-b) – rNix Nov 29 '16 at 05:28

2 Answers2

0

Try to set upload_max_filesize and post_max_size to 0 in php.ini

A.R
  • 112
  • 1
  • 1
  • 11
0

Create a file in PHP containing:

file.php

<----------- start -------------->

<?php

phpinfo();

<----------- end -------------->

Locate the line (Core): upload_max_filesize

If it is not the value you set in the php.ini file, or you changed the wrong file, or you did not restart apache

Also remember that you need to increase post_max_size and memory_limit too.

Rodrigo Prazim
  • 788
  • 7
  • 14