Making WordPress.org


Ignore:
Timestamp:
06/01/2018 04:36:22 PM (8 years ago)
Author:
vedjain
Message:

WCPT: Enqueue select2 library and initialize select2 for all dropdowns in metaboxes.

This will improve searchability. This is only an UX change. Enqueue select library already added in meta.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/wcpt/wcpt-wordcamp/wordcamp-admin.php

    r7098 r7260  
    568568                        );
    569569                }
     570                wp_enqueue_script( 'select2' );
    570571        }
    571572
     
    575576                        wp_enqueue_style( 'wp-datepicker-skins' );
    576577                }
     578                wp_enqueue_style( 'select2' );
    577579        }
    578580
     
    12431245                                                                </select>
    12441246                                                        <?php else : ?>
    1245                                                                 <select name="<?php echo $object_name; ?>" id="<?php echo $object_name; ?>">
     1247                                                                <select name="<?php echo esc_attr( $object_name ); ?>" id="<?php echo esc_attr( $object_name ); ?>" class="select-currency">
    12461248                                                                        <?php foreach ( $currencies as $symbol => $name ) : ?>
    12471249                                                                                <option value="<?php echo esc_attr( $symbol ); ?>"<?php selected( $symbol, get_post_meta( $post_id, $key, true ) ); ?>>
Note: See TracChangeset for help on using the changeset viewer.