Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/clone/wp-conte.../themes/Divi/includes/builder
File: template-preview.php
<?php
[0] Fix | Delete
// Prevent file from being loaded directly
[1] Fix | Delete
if ( ! defined( 'ABSPATH' ) ) {
[2] Fix | Delete
die('-1');
[3] Fix | Delete
}
[4] Fix | Delete
[5] Fix | Delete
et_core_security_check( 'edit_posts', 'et_pb_preview_nonce', '', '_GET' );
[6] Fix | Delete
[7] Fix | Delete
$container_style = isset( $_POST['is_fb_preview'] ) ? 'max-width: none; padding: 0;' : '';
[8] Fix | Delete
$post_id = isset( $_POST['post_id'] ) ? (int) $_POST['post_id'] : 0;
[9] Fix | Delete
[10] Fix | Delete
if ( ! current_user_can( 'edit_post', $post_id ) ) {
[11] Fix | Delete
$post_id = 0;
[12] Fix | Delete
}
[13] Fix | Delete
[14] Fix | Delete
$post = get_post( $post_id );
[15] Fix | Delete
?>
[16] Fix | Delete
<!DOCTYPE html>
[17] Fix | Delete
<html <?php language_attributes(); ?>>
[18] Fix | Delete
<head>
[19] Fix | Delete
<meta charset="<?php bloginfo( 'charset' ); ?>" />
[20] Fix | Delete
[21] Fix | Delete
<?php
[22] Fix | Delete
/**
[23] Fix | Delete
* Fires in the head, before {@see wp_head()} is called. This action can be used to
[24] Fix | Delete
* insert elements into the beginning of the head before any styles are scripts.
[25] Fix | Delete
*
[26] Fix | Delete
* @since 1.0
[27] Fix | Delete
*/
[28] Fix | Delete
do_action( 'et_head_meta' );
[29] Fix | Delete
[30] Fix | Delete
$template_directory_uri = get_template_directory_uri();
[31] Fix | Delete
?>
[32] Fix | Delete
[33] Fix | Delete
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
[34] Fix | Delete
[35] Fix | Delete
<script type="text/javascript">
[36] Fix | Delete
document.documentElement.className = 'js';
[37] Fix | Delete
</script>
[38] Fix | Delete
[39] Fix | Delete
<?php wp_head(); ?>
[40] Fix | Delete
</head>
[41] Fix | Delete
<body <?php body_class(); ?>>
[42] Fix | Delete
<div id="page-container">
[43] Fix | Delete
<div id="main-content">
[44] Fix | Delete
<div class="container" style="<?php echo esc_attr($container_style); ?>">
[45] Fix | Delete
<div id="<?php echo esc_attr( apply_filters( 'et_pb_preview_wrap_id', 'content' ) ); ?>">
[46] Fix | Delete
<div class="<?php echo esc_attr( apply_filters( 'et_pb_preview_wrap_class', 'entry-content post-content entry content' ) ); ?>">
[47] Fix | Delete
[48] Fix | Delete
<?php
[49] Fix | Delete
if ( isset( $_POST['shortcode' ] ) ) {
[50] Fix | Delete
if ( $post ) {
[51] Fix | Delete
// Setup postdata so post-dependent data like dynamic content
[52] Fix | Delete
// can be resolved.
[53] Fix | Delete
setup_postdata( $post );
[54] Fix | Delete
}
[55] Fix | Delete
[56] Fix | Delete
// process content for builder plugin
[57] Fix | Delete
if ( et_is_builder_plugin_active() ) {
[58] Fix | Delete
$content = do_shortcode( wp_unslash( $_POST['shortcode'] ) );
[59] Fix | Delete
$content = str_replace( ']]>', ']]&gt;', $content );
[60] Fix | Delete
[61] Fix | Delete
$content = et_builder_get_builder_content_opening_wrapper() . et_builder_get_layout_opening_wrapper() . $content . et_builder_get_layout_closing_wrapper() . et_builder_get_builder_content_closing_wrapper();
[62] Fix | Delete
} else {
[63] Fix | Delete
$content = apply_filters( 'the_content', wp_unslash( $_POST['shortcode'] ) );
[64] Fix | Delete
$content = str_replace( ']]>', ']]&gt;', $content );
[65] Fix | Delete
}
[66] Fix | Delete
[67] Fix | Delete
if ( $post ) {
[68] Fix | Delete
wp_reset_postdata();
[69] Fix | Delete
}
[70] Fix | Delete
[71] Fix | Delete
echo et_core_intentionally_unescaped( $content, 'html' );
[72] Fix | Delete
} else {
[73] Fix | Delete
printf( '<p class="et-pb-preview-loading"><span>%1$s</span></p>', esc_html__( 'Loading preview...', 'et_builder' ) );
[74] Fix | Delete
}
[75] Fix | Delete
?>
[76] Fix | Delete
[77] Fix | Delete
</div> <!-- .entry-content.post-content.entry -->
[78] Fix | Delete
</div> <!-- #content -->
[79] Fix | Delete
<?php echo et_builder_disabled_link_modal(); ?>
[80] Fix | Delete
</div><!-- .container -->
[81] Fix | Delete
</div><!-- #main-content -->
[82] Fix | Delete
</div> <!-- #page-container -->
[83] Fix | Delete
<?php wp_footer(); ?>
[84] Fix | Delete
</body>
[85] Fix | Delete
</html>
[86] Fix | Delete
[87] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function