Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
  • #1214039

    My problem same as

    I resolve this problem by


    Under this line
    $selected = ( ( $new_std[0] == $post_type ) && isset( $new_std[1] ) ) ? $new_std[1] : 0;

    $selected = apply_filters(‘wpml_object_id’, $selected, $new_std[0], true );

    the enfold version is 4.6.1

    But I recently upgraded the enfold and wordpress versions, and this problem appeared again.

    Wordpress 5.4.1
    enfold 4.7.3

    Can you help me, thank you


    HI~ Please help me.



    Thank you for the info.

    What does the changes fix exactly? As stated on the previous thread, we were not able to reproduce the issue, so we are not entirely sure what needs fixing. Could you explain it a bit?

    Best regards,


    we can reproduce the issue.

    • This reply was modified 3 months, 2 weeks ago by  decode.

    HI~ Please help me.



    Sorry for the delay. We’ll forward these changes to our channel and hopefully add it in the next patch.

    Thank you for your patience.

    Best regards,


    HI~ Thank you for your reply, how long can we get the patch file ?



    We are not really sure about that. You will have to do the modification manually for now.

    Best regards,


    Can you provide patched code?



    We haven’t really looked into the issue because we can’t reproduce it, so we’ll probably add the changes based on what you provided above. Have you tried it again?

    This is the \enfold\config-templatebuilder\avia-template-builder\php\html-helper.class.php file with the modification based on what you described above.


    Best regards,



    I was informed that the patch was already added in the theme and a filter is also available if you need to modify it. The filter is called avf_alb_options_select_hierarchical_post_type_id, and the patch is inside the wp-content\themes\enfold\config-wpml\config.php file.

    		 * Fixes problem with links to posts/pages in ALB elements in modal popup in backend (reported and provided by WPML comp. team)
    		 * @since
    		 * @param int $selected_id
    		 * @param string $object_type			'page' | 'post' | 'category' | ......
    		 * @param array $option_selected
    		 * @param array $element
    		 * @return int
    		function avia_wpml_alb_options_select_hierarchical_post_type_id( $selected_id, $object_type, array $option_selected, array $element )
    			$selected_id = apply_filters( 'wpml_object_id', $selected_id, $option_selected[0], true ); 
    			return $selected_id;
    		add_filter( 'avf_alb_options_select_hierarchical_post_type_id', 'avia_wpml_alb_options_select_hierarchical_post_type_id', 10, 4 );

    Best regards,

Viewing 11 posts - 1 through 11 (of 11 total)

You must be logged in to reply to this topic.