Changeset 7462
- Timestamp:
- 07/13/2018 10:59:06 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-upload.php
r6807 r7462 174 174 </p> 175 175 </form> 176 <script> 176 <?php 177 wp_enqueue_script( 'jquery' ); 178 wp_add_inline_script( 'jquery-migrate', ' 177 179 ( function ( $ ) { 178 var $label = $( 'label.button'),180 var $label = $( "label.button" ), 179 181 labelText = $label.text(); 180 181 $( '#zip_file' ) 182 .on( 'change', function( event ) { 183 var fileName = event.target.value.split( '\\' ).pop(); 184 182 $( "#zip_file" ) 183 .on( "change", function( event ) { 184 var fileName = event.target.value.split( "\\\\" ).pop(); 185 185 fileName ? $label.text( fileName ) : $label.text( labelText ); 186 186 } ) 187 .on( 'focus', function() { $label.addClass( 'focus' ); } ) 188 .on( 'blur', function() { $label.removeClass( 'focus' ); } ); 189 } ( window.jQuery ) ); 190 </script> 191 192 <?php endif; // ! $submitted_counts->total ?> 193 194 <?php else : ?> 195 187 .on( "focus", function() { $label.addClass( "focus" ); } ) 188 .on( "blur", function() { $label.removeClass( "focus" ); } ); 189 } ( window.jQuery ) );' ); 190 191 endif; // ! $submitted_counts->total 192 193 else : ?> 196 194 <p> 197 195 <?php
Note: See TracChangeset
for help on using the changeset viewer.