PATH:
home
/
thebhoeo
/
public_html
/
wp-content
/
themes
/
woodmart
/
inc
/
shortcodes
<?php /** * Shortcode for Popup element. * * @package woodmart */ if ( ! defined( 'WOODMART_THEME_DIR' ) ) { exit( 'No direct script access allowed' ); } if ( ! function_exists( 'woodmart_shortcode_popup' ) ) { /** * Popup shortcode. * * @param array $atts Shortcode attributes. * @param string $content Shortcode content. * * @return string */ function woodmart_shortcode_popup( $atts, $content = '' ) { $parsed_atts = shortcode_atts( array( 'id' => 'my_popup', 'title' => 'GO', 'link' => '', 'custom_attributes' => '', 'width' => 800, 'padding' => '', 'color' => 'default', 'style' => 'default', 'shape' => 'rectangle', 'size' => 'default', 'align' => 'center', 'button_inline' => 'no', 'full_width' => 'no', 'bg_color' => '', 'bg_color_hover' => '', 'color_scheme' => 'light', 'color_scheme_hover' => 'light', 'woodmart_css_id' => '', 'css_animation' => 'none', 'el_class' => '', 'content_class' => '', 'icon_type' => 'icon', 'image' => '', 'img_size' => '25x25', 'icon_fontawesome' => '', 'icon_openiconic' => '', 'icon_typicons' => '', 'icon_entypo' => '', 'icon_linecons' => '', 'icon_monosocial' => '', 'icon_material' => '', 'icon_library' => 'fontawesome', 'icon_position' => 'right', 'css' => '', 'wd_animation' => '', 'wd_animation_delay' => '', 'wd_animation_duration' => '', ), $atts ); extract( $parsed_atts ); // phpcs:ignore WordPress.PHP.DontExtract.extract_extract $inline_styles_settings = array( '--wd-popup-width' => $width . 'px', ); $padding = json_decode( woodmart_decompress( $padding ), true ); if ( isset( $padding['devices']['desktop'] ) ) { $padding = $padding['devices']['desktop']; } if ( isset( $padding['value'] ) && ( ! empty( $padding['value'] ) || '0' === $padding['value'] ) ) { $inline_styles_settings['padding'] = $padding['value'] . ( ! empty( $padding['unit'] ) ? $padding['unit'] : 'px' ); } $inline_styles = ''; foreach ( $inline_styles_settings as $prop => $val ) { $inline_styles .= $prop . ':' . $val . ';'; } ob_start(); $parsed_atts['link'] = 'url:#' . esc_attr( $id ) . '|||'; $parsed_atts['el_class'] = 'wd-open-popup ' . $el_class; $parsed_atts['wrapper_class'] = apply_filters( 'vc_shortcodes_css_class', '', '', $atts ); woodmart_enqueue_js_library( 'magnific' ); woodmart_enqueue_js_script( 'popup-element' ); woodmart_enqueue_inline_style( 'mfp-popup' ); woodmart_enqueue_inline_style( 'mod-animations-transform' ); woodmart_enqueue_inline_style( 'mod-transform' ); echo woodmart_shortcode_button( $parsed_atts, true ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped $content_class = trim( $content_class ); $content_class = ! empty( $content_class ) ? ' ' . esc_attr( $content_class ) : ''; woodmart_set_inline_style_deferred_context( true ); echo '<div id="' . esc_attr( $id ) . '" class="mfp-hide wd-popup wd-popup-element wd-deferred wd-scroll-content' . esc_attr( $content_class ) . '" style="' . esc_attr( $inline_styles ) . '">' . do_shortcode( $content ) . '</div>'; woodmart_set_inline_style_deferred_context( false ); return ob_get_clean(); } }
[-] categories.php
[edit]
[-] brands.php
[edit]
[-] user-panel.php
[edit]
[-] page-heading.php
[edit]
[-] testimonials.php
[edit]
[-] image-hotspot.php
[edit]
[-] posts-slider.php
[edit]
[-] breadcrumbs.php
[edit]
[-] video.php
[edit]
[-] table.php
[edit]
[-] timeline.php
[edit]
[-] contact-form-7.php
[edit]
[-] product-filters.php
[edit]
[-] marquee.php
[edit]
[-] info-box.php
[edit]
[-] social.php
[edit]
[-] toggle.php
[edit]
[-] row-divider.php
[edit]
[-] title.php
[edit]
[-] images-gallery.php
[edit]
[-] responsive-text-block.php
[edit]
[-] image.php
[edit]
[-] team-member.php
[edit]
[-] accordion.php
[edit]
[-] size-guide.php
[edit]
[-] list.php
[edit]
[-] mailchimp.php
[edit]
[-] text-block.php
[edit]
[-] products-tabs.php
[edit]
[-] ajax-search.php
[edit]
[-] slider.php
[edit]
[-] menu-price.php
[edit]
[-] page-title.php
[edit]
[-] blog.php
[edit]
[-] popup.php
[edit]
[-] twitter.php
[edit]
[-] mega-menu.php
[edit]
[-] wc-products-widget.php
[edit]
[-] sidebar.php
[edit]
[-] instagram.php
[edit]
[+]
..
[-] pricing-tables.php
[edit]
[-] nested-carousel.php
[edit]
[-] compare-images.php
[edit]
[-] tabs.php
[edit]
[-] off-canvas-column-btn.php
[edit]
[-] 3d-view.php
[edit]
[-] google-map.php
[edit]
[-] html-block.php
[edit]
[-] countdown-timer.php
[edit]
[-] gallery.php
[edit]
[-] promo-banner.php
[edit]
[-] button.php
[edit]
[-] portfolio.php
[edit]
[-] products.php
[edit]
[-] extra-menu.php
[edit]
[-] open-street-map.php
[edit]
[-] counter.php
[edit]
[-] author-area.php
[edit]