Changeset 39254
- Timestamp:
- 11/15/2016 08:53:18 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-customize-manager.php
r39241 r39254 3553 3553 $height = absint( get_theme_support( 'custom-header', 'height' ) ); 3554 3554 if ( $width && $height ) { 3555 /* translators: %s: header size in pixels */ 3556 $control_description = sprintf( __( 'Upload your video in <code>.mp4</code> format and minimize its file size for best results. Your theme recommends dimensions of %s pixels.' ), 3555 $control_description = sprintf( 3556 /* translators: 1: .mp4, 2: header size in pixels */ 3557 __( 'Upload your video in %1$s format and minimize its file size for best results. Your theme recommends dimensions of %2$s pixels.' ), 3558 '<code>.mp4</code>', 3557 3559 sprintf( '<strong>%s × %s</strong>', $width, $height ) 3558 3560 ); 3559 3561 } elseif ( $width ) { 3560 /* translators: %s: header width in pixels */ 3561 $control_description = sprintf( __( 'Upload your video in <code>.mp4</code> format and minimize its file size for best results. Your theme recommends a width of %s pixels.' ), 3562 $control_description = sprintf( 3563 /* translators: 1: .mp4, 2: header width in pixels */ 3564 __( 'Upload your video in %1$s format and minimize its file size for best results. Your theme recommends a width of %2$s pixels.' ), 3565 '<code>.mp4</code>', 3562 3566 sprintf( '<strong>%s</strong>', $width ) 3563 3567 ); 3564 3568 } else { 3565 /* translators: %s: header height in pixels */ 3566 $control_description = sprintf( __( 'Upload your video in <code>.mp4</code> format and minimize its file size for best results. Your theme recommends a height of %s pixels.' ), 3569 $control_description = sprintf( 3570 /* translators: 1: .mp4, 2: header height in pixels */ 3571 __( 'Upload your video in %1$s format and minimize its file size for best results. Your theme recommends a height of %2$s pixels.' ), 3572 '<code>.mp4</code>', 3567 3573 sprintf( '<strong>%s</strong>', $height ) 3568 3574 ); … … 3973 3979 $size = filesize( $video ); 3974 3980 if ( 8 < $size / pow( 1024, 2 ) ) { // Check whether the size is larger than 8MB. 3975 $validity->add( 'size_too_large', __( 'This video file is too large to use as a header video. Try a shorter video or optimize the compression settings and re-upload a file that is less than 8MB. Or, upload your video to YouTube and link it with the option below.' ) ); 3981 $validity->add( 'size_too_large', 3982 __( 'This video file is too large to use as a header video. Try a shorter video or optimize the compression settings and re-upload a file that is less than 8MB. Or, upload your video to YouTube and link it with the option below.' ) 3983 ); 3976 3984 } 3977 3985 if ( '.mp4' !== substr( $video, -4 ) && '.mov' !== substr( $video, -4 ) ) { // Check for .mp4 or .mov format, which (assuming h.264 encoding) are the only cross-browser-supported formats. 3978 $validity->add( 'invalid_file_type', __( 'Only <code>.mp4</code> or <code>.mov</code> files may be used for header video. Please convert your video file and try again, or, upload your video to YouTube and link it with the option below.' ) ); 3986 $validity->add( 'invalid_file_type', sprintf( 3987 /* translators: 1: .mp4, 2: .mov */ 3988 __( 'Only %1$s or %2$s files may be used for header video. Please convert your video file and try again, or, upload your video to YouTube and link it with the option below.' ), 3989 '<code>.mp4</code>', 3990 '<code>.mov</code>' 3991 ) ); 3979 3992 } 3980 3993 }
Note: See TracChangeset
for help on using the changeset viewer.