Making WordPress.org

Changeset 6626


Ignore:
Timestamp:
02/13/2018 08:14:07 PM (9 years ago)
Author:
iandunn
Message:

Multi Event Sponsors: Apply coding standards.

Location:
sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/classes/mes-sponsor.php

    r5773 r6626  
    1414class MES_Sponsor {
    1515        const POST_TYPE_SLUG = 'mes';
    16        
     16
    1717        /**
    1818         * Constructor
     
    2020        public function __construct() {
    2121                add_action( 'init',                  array( $this, 'create_post_type' ) );
    22                 add_action( 'admin_init',            array( $this, 'add_meta_boxes' ) );
    23                 add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue' ), 20 );
    24                 add_action( 'save_post',             array( $this, 'save_post' ), 10, 2 );
     22                add_action( 'admin_init',            array( $this, 'add_meta_boxes'   ) );
     23                add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue'    ), 20 );
     24                add_action( 'save_post',             array( $this, 'save_post'        ), 10, 2 );
    2525                add_filter( 'the_content',           array( $this, 'add_header_footer_text' ) );
    2626        }
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/classes/mes-sponsorship-level.php

    r1304 r6626  
    1010class MES_Sponsorship_Level {
    1111        const POST_TYPE_SLUG = 'mes-sponsor-level';
    12        
     12
    1313        /**
    1414         * Constructor
     
    1616        public function __construct() {
    1717                add_action( 'init',        array( $this, 'create_post_type' ) );
    18                 add_action( 'admin_init',  array( $this, 'add_meta_boxes' ) );
    19                 add_action( 'save_post',   array( $this, 'save_post' ), 10, 2 );
     18                add_action( 'admin_init',  array( $this, 'add_meta_boxes'   ) );
     19                add_action( 'save_post',   array( $this, 'save_post'        ), 10, 2 );
    2020                add_filter( 'the_content', array( $this, 'add_header_footer_text' ) );
    2121        }
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/classes/multi-event-sponsors.php

    r1719 r6626  
    77class Multi_Event_Sponsors {
    88        const VERSION = '0.1';
    9        
     9
    1010        /**
    1111         * Constructor
     
    8989         *
    9090         * @param array $sponsors
    91          * @param array $regions
    9291         *
    9392         * @return array
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/views/metabox-contact-information.php

    r6625 r6626  
    55                <tr>
    66                        <th><label for="mes_company_name"><?php _e( 'Company Name:', 'wordcamporg' ); ?></label></th>
    7        
     7
    88                        <td>
    99                                <input id="mes_company_name" name="mes_company_name" type="text" value="<?php echo esc_attr( $company_name ); ?>" required class="regular-text" />
     
    1111                        </td>
    1212                </tr>
    13                
     13
    1414                <tr>
    1515                        <th><label for="mes_website"><?php _e( 'Website:', 'wordcamporg' ); ?></label></th>
    16        
     16
    1717                        <td>
    1818                                <input id="mes_website" name="mes_website" type="url" value="<?php echo esc_attr( $website ); ?>" required class="regular-text" />
     
    2020                        </td>
    2121                </tr>
    22                
     22
    2323                <tr>
    2424                        <th><label for="mes_first_name"><?php _e( 'First Name:', 'wordcamporg' ); ?></label></th>
    25        
     25
    2626                        <td>
    2727                                <input id="mes_first_name" name="mes_first_name" type="text" value="<?php echo esc_attr( $first_name ); ?>" required class="regular-text" />
     
    4747                        </td>
    4848                </tr>
    49        
     49
    5050                <tr>
    5151                        <th><label for="mes_phone_number"><?php _e( 'Phone Number:', 'wordcamporg' ); ?></label></th>
    52        
     52
    5353                        <td>
    5454                                <input id="mes_phone_number" name="mes_phone_number" type="text" value="<?php echo esc_attr( $phone_number ); ?>" required class="regular-text" />
     
    7171                        </td>
    7272                </tr>
    73        
     73
    7474                <tr>
    7575                        <th><label for="mes_street_address2"><?php _e( 'Street Address 2:', 'wordcamporg' ); ?></label></th>
     
    7979                        </td>
    8080                </tr>
    81        
     81
    8282                <tr>
    8383                        <th><label for="mes_city"><?php _e( 'City:', 'wordcamporg' ); ?></label></th>
     
    8888                        </td>
    8989                </tr>
    90        
     90
    9191                <tr>
    9292                        <th><label for="mes_state"><?php _e( 'State:', 'wordcamporg' ); ?></label></th>
     
    9797                        </td>
    9898                </tr>
    99        
     99
    100100                <tr>
    101101                        <th><label for="mes_zip_code"><?php _e( 'Zip Code:', 'wordcamporg' ); ?></label></th>
     
    106106                        </td>
    107107                </tr>
    108        
     108
    109109                <tr>
    110110                        <th><label for="mes_country"><?php _e( 'Country:', 'wordcamporg' ); ?></label></th>
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/views/metabox-sponsor-agreement.php

    r5772 r6626  
    11<?php
    2 /* @var int $agreement_id */
     2/* @var int    $agreement_id */
    33/* @var string $agreement_url */
    4 ?>
    54
    6 <?php
    75// Use the WC Post Types template if available.
    86$template_file = dirname( plugin_dir_path( __FILE__ ), 2 ) . '/wc-post-types/views/sponsors/metabox-sponsor-agreement.php';
     7
    98if ( is_readable( $template_file ) ) :
    109        require_once $template_file;
    1110else :
    12 // WC Post Types template unavailable.
    13 ?>
    14 <p id="sponsor-agreement-description-container" class="description hidden">
    15         <?php
    16         printf(
    17                 wp_kses(
    18                         __( '<strong>Instructions:</strong> You can generate an agreement for this sponsor <a href="%s">here</a>. Upload a PDF or image file of the signed, dated sponsor agreement.', 'wordcamporg' ),
    19                         array(
    20                                 'a' => array( 'href' => true ),
    21                                 'strong' => true,
    22                         )
    23                 ),
    24                 esc_url( add_query_arg( array( 'page' => 'wcdocs' ), admin_url( 'admin.php' ) ) )
    25         );
     11        // WC Post Types template unavailable.
    2612        ?>
    27 </p>
    28 <p id="sponsor-agreement-upload-container" class="hidden">
    29         <a id="sponsor-agreement-upload" class="button secondary" href="#"><?php esc_html_e( 'Attach Signed Agreement', 'wordcamporg' ); ?></a>
    30 </p>
    3113
    32 <p id="sponsor-agreement-view-container" class="hidden">
    33         <a id="sponsor-agreement-view" class="button secondary" href="<?php echo esc_url( $agreement_url ); ?>" target="sponsor-agreement"><?php esc_html_e( 'View Agreement', 'wordcamporg' ); ?></a>
    34 </p>
    35 <p id="sponsor-agreement-remove-container" class="hidden">
    36         <a id="sponsor-agreement-remove" href="#"><?php esc_html_e( 'Remove Agreement', 'wordcamporg' ); ?></a>
    37 </p>
     14        <p id="sponsor-agreement-description-container" class="description hidden">
     15                <?php
     16                printf(
     17                        wp_kses(
     18                                __( '<strong>Instructions:</strong> You can generate an agreement for this sponsor <a href="%s">here</a>. Upload a PDF or image file of the signed, dated sponsor agreement.', 'wordcamporg' ),
     19                                array(
     20                                        'a' => array( 'href' => true ),
     21                                        'strong' => true,
     22                                )
     23                        ),
     24                        esc_url( add_query_arg( array( 'page' => 'wcdocs' ), admin_url( 'admin.php' ) ) )
     25                );
     26                ?>
     27        </p>
    3828
    39 <input id="sponsor-agreement-id" name="_wcpt_sponsor_agreement" type="hidden" value="<?php echo esc_attr( $agreement_id ); ?>" />
    40 <?php endif; ?>
     29        <p id="sponsor-agreement-upload-container" class="hidden">
     30                <a id="sponsor-agreement-upload" class="button secondary" href="#"><?php esc_html_e( 'Attach Signed Agreement', 'wordcamporg' ); ?></a>
     31        </p>
     32
     33        <p id="sponsor-agreement-view-container" class="hidden">
     34                <a id="sponsor-agreement-view" class="button secondary" href="<?php echo esc_url( $agreement_url ); ?>" target="sponsor-agreement">
     35                        <?php esc_html_e( 'View Agreement', 'wordcamporg' ); ?>
     36                </a>
     37        </p>
     38
     39        <p id="sponsor-agreement-remove-container" class="hidden">
     40                <a id="sponsor-agreement-remove" href="#"><?php esc_html_e( 'Remove Agreement', 'wordcamporg' ); ?></a>
     41        </p>
     42
     43        <input id="sponsor-agreement-id" name="_wcpt_sponsor_agreement" type="hidden" value="<?php echo esc_attr( $agreement_id ); ?>" />
     44
     45<?php endif;
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/views/shortcode-multi-event-sponsors.php

    r623 r6626  
    2121        </ul>
    2222
    23 <?php endforeach; ?>
     23<?php endforeach;
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/views/taxonomy-meta-region.php

    r6616 r6626  
    3030        </div>
    3131
    32 <?php endif; ?>
     32<?php endif;
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/multi-event-sponsors/views/template-region-dropdown.php

    r4256 r6626  
    2222                Push sponsors to site
    2323        </label>
    24 <?php endif; ?>
     24<?php endif;
Note: See TracChangeset for help on using the changeset viewer.