Support

Account

Home Forums Backend Issues (wp-admin) Translate post_type in realtionship UI Reply To: Translate post_type in realtionship UI

  • Hi elliot – thank you so much! Amazing support here!

    Note: these changes should also be made to the right side of the UI on line 495, although a little different:

    changing:
    $title .= $p->post_type;

    To:

    $post_type_object = get_post_type_object( get_post_type( $p ) );
    $title .= $post_type_object->labels->singular_name;

    And also in the “select”, where you can select a posttype. Current code looks like this around line 451:

    foreach( $field['post_type'] as $post_type )
    	{
    	$choices[ $post_type ] = $post_type;
    	}

    Im not completely sure what the best way would be here, as i don’t quite understand the acf filters.

    But that should then fix it for this field, i think. Im impressed with the quick response!