'attrs' => $featured_image_attrs,
$featured_image_output = $multi_view->render_element(
'content' => sprintf( '<div class="et_pb_title_featured_image"><span class="et_pb_image_wrap">%1$s</span></div>', $featured_image_content ),
'class' => 'et_pb_title_featured_container',
'featured_image' => 'on',
'featured_image' => 'on',
'base_attr_name' => 'image_height',
'selector' => '%%order_class%% .et_pb_title_featured_container img',
'css_property' => 'height',
'render_slug' => $render_slug,
'base_attr_name' => 'image_max_height',
'selector' => '%%order_class%% .et_pb_title_featured_container img',
'css_property' => 'max-height',
'render_slug' => $render_slug,
if ( 'off' === $this->props['force_fullwidth'] ) {
'base_attr_name' => 'image_width',
'selector' => '%%order_class%% .et_pb_title_featured_image',
'css_property' => 'width',
'render_slug' => $render_slug,
'base_attr_name' => 'image_max_width',
'selector' => '%%order_class%% .et_pb_title_featured_image',
'css_property' => 'max-width',
'render_slug' => $render_slug,
$image_alignment_values = et_pb_responsive_options()->get_property_values( $this->props, 'image_alignment', 'none' );
et_pb_responsive_options()->generate_responsive_css(
'%%order_class%% .et_pb_title_featured_image',
$image_alignments = array(
'left' => 'auto auto auto 0',
'right' => 'auto 0 auto auto',
foreach ( $image_alignment_values as $breakpoint => $alignment ) {
$image_alignment_values[ $breakpoint ] = et_()->array_get(
et_pb_responsive_options()->generate_responsive_css(
'%%order_class%% .et_pb_title_featured_image',
ET_Builder_Element::set_style(
'selector' => '%%order_class%% .et_pb_image_wrap',
'declaration' => 'width: auto;',
if ( $multi_view->has_value( 'title', 'on' ) ) {
if ( is_et_pb_preview() && isset( $_POST['post_title'] ) && wp_verify_nonce( $_POST['et_pb_preview_nonce'], 'et_pb_preview_nonce' ) ) {
$post_title = esc_html( sanitize_text_field( wp_unslash( $_POST['post_title'] ) ) );
// Unescaped for backwards compat reasons.
$post_title = et_core_intentionally_unescaped( et_builder_get_current_title(), 'html' );
$output .= $multi_view->render_element(
'tag' => et_pb_process_header_level( $header_level, 'h1' ),
'content' => $post_title,
'class' => 'entry-title',
if ( $post_id && $multi_view->has_value( 'meta', 'on' ) ) {
foreach ( array( 'author', 'date', 'categories', 'comments' ) as $single_meta ) {
if ( 'categories' === $single_meta && ! is_singular( 'post' ) ) {
$meta_array[] = $multi_view->render_element(
'content' => et_pb_postinfo_meta( array( $single_meta ), $date_format, esc_html__( '0 comments', 'et_builder' ), esc_html__( '1 comment', 'et_builder' ), '% ' . esc_html__( 'comments', 'et_builder' ) ),
'et_pb_title_meta_item--visible' => array(
$output .= $multi_view->render_element(
'content' => implode( '', $meta_array ),
'class' => 'et_pb_title_meta_container',
if ( 'on' === $text_background ) {
// Text Background Color.
'base_attr_name' => 'text_bg_color',
'selector' => '%%order_class%% .et_pb_title_container',
'css_property' => 'background-color',
'render_slug' => $render_slug,
'additional_css' => 'padding: 1em 1.5em;',
$video_background = $this->video_background();
$background_layout = 'dark' === $text_color ? 'light' : 'dark';
$data_background_layout = '';
$data_background_layout_hover = '';
if ( et_pb_hover_options()->is_enabled( 'text_color', $this->props ) && ! empty( $text_color_hover ) && $text_color !== $text_color_hover ) {
$data_background_layout = sprintf( ' data-background-layout="%1$s"', esc_attr( $text_color_hover ) );
$data_background_layout_hover = sprintf( ' data-background-layout-hover="%1$s"', esc_attr( $text_color ) );
$this->get_text_orientation_classname(),
"et_pb_bg_layout_{$background_layout}",
if ( 'on' === $multi_view->get_value( 'featured_image' ) && 'background' === $featured_placement ) {
$this->add_classname( 'et_pb_featured_bg' );
if ( 'above' === $featured_placement ) {
$this->add_classname( 'et_pb_image_above' );
if ( 'below' === $featured_placement ) {
$this->add_classname( 'et_pb_image_below' );
// Remove automatically added classnames
'et_pb_fullwidth_post_title',
$muti_view_data_attr = $multi_view->render_attrs(
'et_pb_featured_bg' => array(
'featured_image' => 'on',
'featured_placement' => 'background',
'<div%3$s class="%2$s" %8$s %9$s %10$s>
<div class="et_pb_title_container">
$this->module_classname( $render_slug ),
$parallax_image_background,
'on' === $featured_image && 'above' === $featured_placement ? $featured_image_output : '', // #5
'on' === $featured_image && 'below' === $featured_placement ? $featured_image_output : '',
$data_background_layout_hover,
et_core_esc_previously( $muti_view_data_attr ) // #10
new ET_Builder_Module_Fullwidth_Post_Title();