Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if($bg_options == 'video'){
- $filetype = wp_check_filetype($atts['background_options']['video']['video']);
- $filetypes = array('mp4' => 'mp4', 'ogv' => 'ogg', 'webm' => 'webm', 'jpg' => 'poster');
- $filetype = array_key_exists((string) $filetype['ext'], $filetypes) ? $filetypes[$filetype['ext']] : 'video';
- $bg_video_data_attr = 'data-wallpaper-options="' . fw_htmlspecialchars(json_encode(array('source' => array($filetype => $atts['background_options']['video']['video'])))) . '"';
- $section_extra_classes .= ' background-video';
- $overlays = $atts['background_options']['video']['overlay_options']['yes']['background'];
- $overlay = "style='background-color:$overlays;z-index:3;position:relative;'";
- }
- ?>
- <section id="<?php echo $id; ?>" class="fw-main-row <?php echo $section_extra_classes ?> <?php echo $custom_class; ?>" <?php echo $section_style; ?> <?php echo $bg_video_data_attr; ?> >
- <div <?php echo $overlay; ?>>
- <div class="<?php echo $container_class; ?> <?php echo $space ?>">
- <?php echo do_shortcode($content); ?>
- </div>
- </div>
- </section>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement