Skip to content

Commit

Permalink
remove video script enqueue
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidCramer committed May 31, 2018
1 parent f5ca657 commit 601c005
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions includes/class-amp-theme-support.php
Expand Up @@ -1292,7 +1292,8 @@ public static function conditionally_output_header( $html, $header, $atts ) {
* @return string $html Filtered markup.
*/
public static function output_header_video( $atts ) {

// Remove the script for video.
wp_deregister_script( 'wp-custom-header' );
$video_settings = get_header_video_settings();

$parsed_url = wp_parse_url( $video_settings['videoUrl'] );
Expand All @@ -1319,6 +1320,7 @@ public static function output_header_video( $atts ) {
'data-videoid' => $query['v'],
'data-param-rel' => '0', // Don't show related videos.
'data-param-showinfo' => '0', // Don't show video title at the top.
'data-param-controls' => '0', // Don't show video controls.
)
)
);
Expand Down Expand Up @@ -1353,7 +1355,7 @@ public static function output_header_image( $atts ) {
$atts['layout'] = 'fill';
unset( $atts['width'] );

$place_holder = AMP_HTML_Utils::build_tag( 'amp-img', $atts );
$place_holder = AMP_HTML_Utils::build_tag( 'img', $atts );

return $place_holder;

Expand Down

0 comments on commit 601c005

Please sign in to comment.