|
@@ 724-730 (lines=7) @@
|
| 721 |
|
*/ |
| 722 |
|
public function step_2() { |
| 723 |
|
check_admin_referer('custom-header-upload', '_wpnonce-custom-header-upload'); |
| 724 |
|
if ( ! current_theme_supports( 'custom-header', 'uploads' ) ) { |
| 725 |
|
wp_die( |
| 726 |
|
'<h1>' . __( 'Cheatin’ uh?' ) . '</h1>' . |
| 727 |
|
'<p>' . __( 'The current theme does not support uploading a custom header image.' ) . '</p>', |
| 728 |
|
403 |
| 729 |
|
); |
| 730 |
|
} |
| 731 |
|
|
| 732 |
|
if ( empty( $_POST ) && isset( $_GET['file'] ) ) { |
| 733 |
|
$attachment_id = absint( $_GET['file'] ); |
|
@@ 882-888 (lines=7) @@
|
| 879 |
|
public function step_3() { |
| 880 |
|
check_admin_referer( 'custom-header-crop-image' ); |
| 881 |
|
|
| 882 |
|
if ( ! current_theme_supports( 'custom-header', 'uploads' ) ) { |
| 883 |
|
wp_die( |
| 884 |
|
'<h1>' . __( 'Cheatin’ uh?' ) . '</h1>' . |
| 885 |
|
'<p>' . __( 'The current theme does not support uploading a custom header image.' ) . '</p>', |
| 886 |
|
403 |
| 887 |
|
); |
| 888 |
|
} |
| 889 |
|
|
| 890 |
|
if ( ! empty( $_POST['skip-cropping'] ) && ! ( current_theme_supports( 'custom-header', 'flex-height' ) || current_theme_supports( 'custom-header', 'flex-width' ) ) ) { |
| 891 |
|
wp_die( |