vc-tweetmeme.php 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. <?php
  2. if ( ! defined( 'ABSPATH' ) ) {
  3. die( '-1' );
  4. }
  5. /**
  6. * Class WPBakeryShortCode_Vc_TweetMeMe
  7. */
  8. class WPBakeryShortCode_Vc_TweetMeMe extends WPBakeryShortCode {
  9. /**
  10. * @param $atts
  11. * @param null $content
  12. * @return string
  13. * @throws \Exception
  14. */
  15. protected function contentInline( $atts, $content = null ) {
  16. /**
  17. * Shortcode attributes
  18. * @var $atts
  19. * Shortcode class
  20. * @var WPBakeryShortCode_Vc_TweetMeMe $this
  21. */
  22. $atts = vc_map_get_attributes( $this->getShortcode(), $atts );
  23. $css = isset( $atts['css'] ) ? $atts['css'] : '';
  24. $el_class = isset( $atts['el_class'] ) ? $atts['el_class'] : '';
  25. $class_to_filter = 'wpb_googleplus vc_social-placeholder wpb_content_element';
  26. $class_to_filter .= vc_shortcode_custom_css_class( $css, ' ' ) . $this->getExtraClass( $el_class ) . $this->getCSSAnimation( $atts['css_animation'] );
  27. $css_class = apply_filters( VC_SHORTCODE_CUSTOM_CSS_FILTER_TAG, $class_to_filter, $this->settings['base'], $atts );
  28. return '<div class="' . esc_attr( $css_class ) . '"></div>';
  29. }
  30. }