Home Forums Bug Reports Undefined indexes


Undefined indexes

  • Hi!

    I’ve been using ACF in my project for a long time but faced with a problem today. After updating Field Group I got an error:
    Notice: Undefined variable: field in ... advanced-custom-fields/core/fields/_functions.php on line 525
    Then I just updated the page and got another error:
    Notice: Undefined index: formatting in ... /core/fields/text.php on line 262 & 266

    Since that time I have second error on all my pages.

    I made a quick fix:

    		if (isset($field['formatting'])) {
    			if( $field['formatting'] == 'none' )
    				$value = htmlspecialchars($value, ENT_QUOTES);
    			elseif( $field['formatting'] == 'html' )
    				$value = nl2br($value);

    But not sure why this happened and what is the proper way to fix it.

    PHP version 5.6.3
    WP version: 4.0
    ACF version: 4.3.9
    Advanced Custom Fields: Repeater Field v1.1.1,
    Advanced Custom Fields: qTranslate v 1.4

  • This reply has been marked as private.
Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.