WordPress.org

Plugin Directory

Changeset 530486


Ignore:
Timestamp:
04/13/12 01:02:42 (2 years ago)
Author:
sterlo
Message:

Scope and whitespace.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • scalable-vector-graphics-svg/trunk/scalable-vector-graphics.php

    r530485 r530486  
    2727 
    2828    public function execute() { 
    29         add_filter( 'upload_mimes' , array( &$this , 'allow_svg_uploads' ) ); 
    30         add_shortcode( 'svg' , array( &$this , 'process_shortcode' ) ); 
     29        add_filter( 'upload_mimes', array( &$this, 'allow_svg_uploads' ) ); 
     30        add_shortcode( 'svg', array( &$this, 'process_shortcode' ) ); 
    3131    } 
    3232 
    33     function allow_svg_uploads( $existing_mime_types = array() ) { 
     33    public function allow_svg_uploads( $existing_mime_types = array() ) { 
    3434        $new_mime_types = $existing_mime_types; 
    3535        $new_mime_types[ 'svg' ] = 'mime/type'; 
     
    3838    } 
    3939 
    40     function process_shortcode( $atts ) { 
     40    public function process_shortcode( $atts ) { 
    4141        $valid_attributes = array( 'src' , 'style' , 'type' , 'width' , 'height' ); 
    4242 
     
    4444 
    4545        foreach( $atts as $attribute => $value ) { 
    46             if( ! in_array( $attribute , $valid_attributes ) ) { 
     46            if( ! in_array( $attribute, $valid_attributes ) ) { 
    4747                $content .= "\n" . '<!-- Invalid attribute ignored: ' . $attribute . ' -->' . "\n"; 
    4848            } 
     
    6666} 
    6767 
    68 if ( class_exists( 'scalable_vector_graphics' ) and !isset( $scalable_vector_graphics ) ) { 
     68if ( class_exists( 'scalable_vector_graphics' ) and ! isset( $scalable_vector_graphics ) ) { 
    6969    $scalable_vector_graphics = new scalable_vector_graphics(); 
    7070    $scalable_vector_graphics->execute(); 
Note: See TracChangeset for help on using the changeset viewer.