themeeewee_shortcode_movie_function

The Eewee responsive design themeeewee shortcode movie function function.

Description

themeeewee_shortcode_movie_function( $atts, (constant) $content = null ); 

Parameters (2)

0. $atts
The atts.
1. $content — Optional. (constant) => null
The content.

Usage

  1. if ( !function_exists( 'themeeewee_shortcode_movie_function' ) ) { 
  2. require_once '/includes/shortcodes/movie/movie.php'; 
  3.  
  4. // The atts. 
  5. $atts = null; 
  6.  
  7. // The content. 
  8. $content = null; 
  9.  
  10. // NOTICE! Understand what this does before running. 
  11. $result = themeeewee_shortcode_movie_function($atts, $content); 
  12.  

Defined (1)

The function is defined in the following location(s).

/includes/shortcodes/movie/movie.php  
  1. function themeeewee_shortcode_movie_function($atts, $content = null) { 
  2.  
  3. extract(shortcode_atts(array( 
  4. 'type' => '',  
  5. 'code' => '',  
  6. 'width' => '',  
  7. 'height' => '' 
  8. ), $atts)); 
  9.  
  10. switch( $type ) { 
  11. case "youtube" : 
  12. $movie = ' 
  13. <iframe width="'.$width.'" height="'.$height.'" src="http://www.youtube.com/embed/'.$code.'" frameborder="0" allowfullscreen></iframe>'; 
  14. break; 
  15.  
  16. case "vimeo" : 
  17. $movie = ' 
  18. <iframe src="http://player.vimeo.com/video/'.$code.'?title=0&byline=0&portrait=0&color=0d0d0d" width="'.$width.'" height="'.$height.'" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe>'; 
  19. break; 
  20.  
  21. case "dailymotion" : 
  22. $movie = ' 
  23. <iframe frameborder="0" width="'.$width.'" height="'.$height.'" src="http://www.dailymotion.com/embed/video/'.$code.'"></iframe><br />'; 
  24. break; 
  25.  
  26. default :  
  27. $movie = ""; 
  28.  
  29.  
  30. return "<div class='shortcode_movie'>".$movie."</div>";