646 | | printf( |
647 | | /* translators: 1: Theme name, 2: Details URL, 3: Additional link attributes, 4: Version number, 5: Update URL, 6: Additional link attributes. */ |
648 | | __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a> or <a href="%5$s" %6$s>update now</a>.' ), |
649 | | $theme['Name'], |
650 | | esc_url( $details_url ), |
651 | | sprintf( |
652 | | 'class="thickbox open-plugin-details-modal" aria-label="%s"', |
653 | | /* translators: 1: Theme name, 2: Version number. */ |
654 | | esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme['Name'], $response['new_version'] ) ) |
655 | | ), |
656 | | $response['new_version'], |
657 | | wp_nonce_url( self_admin_url( 'update.php?action=upgrade-theme&theme=' ) . $theme_key, 'upgrade-theme_' . $theme_key ), |
658 | | sprintf( |
659 | | 'class="update-link" aria-label="%s"', |
660 | | /* translators: %s: Theme name. */ |
661 | | esc_attr( sprintf( __( 'Update %s now' ), $theme['Name'] ) ) |
662 | | ) |
663 | | ); |
| 648 | if ( $compatible_wp && $compatible_php ) { |
| 649 | printf( |
| 650 | /* translators: 1: Theme name, 2: Details URL, 3: Additional link attributes, 4: Version number, 5: Update URL, 6: Additional link attributes. */ |
| 651 | __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a> or <a href="%5$s" %6$s>update now</a>.' ), |
| 652 | $theme['Name'], |
| 653 | esc_url( $details_url ), |
| 654 | sprintf( |
| 655 | 'class="thickbox open-plugin-details-modal" aria-label="%s"', |
| 656 | /* translators: 1: Theme name, 2: Version number. */ |
| 657 | esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme['Name'], $response['new_version'] ) ) |
| 658 | ), |
| 659 | $response['new_version'], |
| 660 | wp_nonce_url( self_admin_url( 'update.php?action=upgrade-theme&theme=' ) . $theme_key, 'upgrade-theme_' . $theme_key ), |
| 661 | sprintf( |
| 662 | 'class="update-link" aria-label="%s"', |
| 663 | /* translators: %s: Theme name. */ |
| 664 | esc_attr( sprintf( __( 'Update %s now' ), $theme['Name'] ) ) |
| 665 | ) |
| 666 | ); |
| 667 | } else { |
| 668 | printf( |
| 669 | /* translators: 1: Theme name, 2: Details URL, 3: Additional link attributes, 4: Version number, 5: Update URL, 6: Additional link attributes. */ |
| 670 | __( 'There is a new version of %1$s available. <a href="%2$s" %3$s>View version %4$s details</a>.<br>Current theme requirements not met. This theme requires WordPress %5$s and PHP %6$s.' ), |
| 671 | $theme['Name'], |
| 672 | esc_url( $details_url ), |
| 673 | sprintf( |
| 674 | 'class="thickbox open-plugin-details-modal" aria-label="%s"', |
| 675 | /* translators: 1: Theme name, 2: Version number. */ |
| 676 | esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $theme['Name'], $response['new_version'] ) ) |
| 677 | ), |
| 678 | $response['new_version'], |
| 679 | $theme->get( 'Requires' ), |
| 680 | $theme->get( 'RequiresPHP' ) |
| 681 | ); |
| 682 | } |