Changing Default Contents

Use upb_element_{$tag}_contents filter to change default content of an element.


add_filter("upb_element_{$tag}_contents", function($content){
    return 'Demo Contents';

Example (Nested Element Contents like: upb-accordion):

add_filter("upb_element_{$tag}_contents", function($contents){
   $contents = array(
            upb_elements()->generate_element( 'upb-accordion-item', '<p>Authoritatively formulate one-to-one interfaces with sustainable information. Collaboratively impact value-added meta-services rather than superior growth.</p>', array( 'active' => TRUE, 'title' => esc_html__( 'Accordion Item 1', 'ultimate-page-builder' ) ) ),

            upb_elements()->generate_element( 'upb-accordion-item', '<p>Holisticly customize top-line leadership skills for wireless solutions. Appropriately actualize principle-centered products rather than sustainable.</p>', array( 'active' => FALSE, 'title' => esc_html__( 'Accordion Item 2', 'ultimate-page-builder' ) ) )

        return $contents;

results matching ""

    No results matching ""