Changeset 62844
- Timestamp:
- 07/24/2026 03:47:25 PM (44 hours ago)
- File:
-
- 1 edited
-
trunk/src/wp-admin/options-privacy.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/options-privacy.php
r61456 r62844 52 52 53 53 if ( 'set-privacy-page' === $action ) { 54 $privacy_policy_page_id = isset( $_POST['page_for_privacy_policy'] ) ? (int) $_POST['page_for_privacy_policy'] : 0; 54 $previous_privacy_policy_page_id = (int) get_option( 'wp_page_for_privacy_policy' ); 55 $privacy_policy_page_id = isset( $_POST['page_for_privacy_policy'] ) ? (int) $_POST['page_for_privacy_policy'] : 0; 55 56 update_option( 'wp_page_for_privacy_policy', $privacy_policy_page_id ); 56 57 57 $privacy_page_ updated_message = __( 'Privacy Policy page updated successfully.' );58 $privacy_page_message_type = 'success'; 58 59 59 60 if ( $privacy_policy_page_id ) { 61 $privacy_page_updated_message = __( 'Privacy Policy page updated successfully.' ); 62 60 63 /* 61 64 * Don't always link to the menu customizer: … … 76 79 ); 77 80 } 78 } 79 80 add_settings_error( 'page_for_privacy_policy', 'page_for_privacy_policy', $privacy_page_updated_message, 'success' ); 81 } elseif ( $previous_privacy_policy_page_id ) { 82 // A previously set Privacy Policy page was cleared. 83 $privacy_page_updated_message = __( 'Privacy Policy page removed.' ); 84 } else { 85 // No Privacy Policy page was set before, and none is set now. 86 $privacy_page_updated_message = __( 'No Privacy Policy page is currently set.' ); 87 $privacy_page_message_type = 'info'; 88 } 89 90 add_settings_error( 'page_for_privacy_policy', 'page_for_privacy_policy', $privacy_page_updated_message, $privacy_page_message_type ); 81 91 } elseif ( 'create-privacy-page' === $action ) { 82 92
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)