public function sanitizeEndDate($data)
    {
        $data = strtotime($data);

        if ($data == false) {
            $data = strtotime('today midnight');
        }

        $data = strtotime('+1 day', $data) - 1;

        return date('Y-m-d H:i:s', $data);
    }
public function sanitizeEndDate($data)
    {
        $data = strtotime($data);

        if ($data == false) {
            $data = strtotime('today midnight');
        }

        $data = strtotime('+1 day', $data) - 1;

        return date('Y-m-d H:i:s', $data);
    }
public function sanitizeEndDate ( $ data ) { $ data = strtotime ( $ data ) ; if ( $ data == false ) { $ data = strtotime ( 'today midnight' ) ; } $ data = strtotime ( '+1 day' , $ data ) - 1 ; return date ( 'Y-m-d H:i:s' , $ data ) ; }
Sanitize end date. Add 1 day to include events occurring on end date
@param $data
@return int
Sanitize end date . Add 1 day to include events occurring on end date