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

Warning: Undefined array key "page_file_edit_line" in /home/sportsfever/public_html/filemanger/edit_text_line.php on line 32
/home/sportsfe.../httpdocs/wp-conte.../plugins/embedpre.../EmbedPre.../Includes/Classes
File: Elementor_Enhancer.php
}
[500] Fix | Delete
$muted = ( 'yes' === $settings['embedpress_pro_twitch_mute'] ) ? 'true' : 'false';
[501] Fix | Delete
$theme = !empty($settings['embedpress_pro_twitch_theme']) ? esc_attr($settings['embedpress_pro_twitch_theme']) : 'dark';
[502] Fix | Delete
[503] Fix | Delete
if ( is_embedpress_pro_active() ) {
[504] Fix | Delete
[505] Fix | Delete
$layout = ( 'yes' === $settings['embedpress_pro_twitch_chat'] ) ? 'video-with-chat' : 'video';
[506] Fix | Delete
[507] Fix | Delete
}
[508] Fix | Delete
[509] Fix | Delete
$url = "https://embed.twitch.tv?autoplay={$autoplay}&channel={$channel}&height={$height}&layout={$layout}&migration=true&muted={$muted}&theme={$theme}&time={$time}&video={$video}&width={$width}&allowfullscreen={$full_screen}";
[510] Fix | Delete
[511] Fix | Delete
$pars_url = wp_parse_url( get_site_url() );
[512] Fix | Delete
$url = ! empty( $pars_url['host'] ) ? $url . '&parent=' . $pars_url['host'] : $url;
[513] Fix | Delete
[514] Fix | Delete
preg_match( '/src=\"(.+?)\"/', $embed_content->embed, $match );
[515] Fix | Delete
$url_full = $match[1];
[516] Fix | Delete
$embed_content->embed = str_replace( $url_full, $url, $embed_content->embed );
[517] Fix | Delete
if ( is_embedpress_pro_active() ) {
[518] Fix | Delete
return self::apply_cta_markup( $embed_content, $settings, 'twitch' );
[519] Fix | Delete
}
[520] Fix | Delete
[521] Fix | Delete
return $embed_content;
[522] Fix | Delete
}
[523] Fix | Delete
[524] Fix | Delete
public static function spotify( $embed, $setting ) {
[525] Fix | Delete
if ( ! isset( $embed->provider_name ) || strtolower( $embed->provider_name ) !== 'spotify' || ! isset( $embed->embed ) ) {
[526] Fix | Delete
return $embed;
[527] Fix | Delete
}
[528] Fix | Delete
preg_match( '/src=\"(.+?)\"/', $embed->embed, $match );
[529] Fix | Delete
$url_full = $match[1];
[530] Fix | Delete
$modified_url = str_replace( 'playlist-v2', 'playlist', $url_full );
[531] Fix | Delete
if ( $setting['embedpress_pro_embeded_source'] == 'spotify' ) {
[532] Fix | Delete
// apply elementor related mod
[533] Fix | Delete
if ( isset( $setting['spotify_theme'] ) ) {
[534] Fix | Delete
if ( strpos( $modified_url, '?' ) !== false ) {
[535] Fix | Delete
$modified_url .= '&theme=' . sanitize_text_field( $setting['spotify_theme'] );
[536] Fix | Delete
} else {
[537] Fix | Delete
$modified_url .= '?theme=' . sanitize_text_field( $setting['spotify_theme'] );
[538] Fix | Delete
}
[539] Fix | Delete
}
[540] Fix | Delete
}
[541] Fix | Delete
[542] Fix | Delete
$embed->embed = str_replace( $url_full, $modified_url, $embed->embed );
[543] Fix | Delete
[544] Fix | Delete
return $embed;
[545] Fix | Delete
}
[546] Fix | Delete
}
[547] Fix | Delete
12
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function