--- a/wp/wp-admin/options-permalink.php Wed Sep 21 18:19:35 2022 +0200
+++ b/wp/wp-admin/options-permalink.php Tue Sep 27 16:37:53 2022 +0200
@@ -13,6 +13,7 @@
wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) );
}
+// Used in the HTML title tag.
$title = __( 'Permalink Settings' );
$parent_file = 'options-general.php';
@@ -55,12 +56,18 @@
)
);
-get_current_screen()->set_help_sidebar(
- '<p><strong>' . __( 'For more information:' ) . '</strong></p>' .
- '<p>' . __( '<a href="https://wordpress.org/support/article/settings-permalinks-screen/">Documentation on Permalinks Settings</a>' ) . '</p>' .
- '<p>' . __( '<a href="https://wordpress.org/support/article/using-permalinks/">Documentation on Using Permalinks</a>' ) . '</p>' .
- '<p>' . __( '<a href="https://wordpress.org/support/">Support</a>' ) . '</p>'
-);
+$help_sidebar_content = '<p><strong>' . __( 'For more information:' ) . '</strong></p>' .
+ '<p>' . __( '<a href="https://wordpress.org/support/article/settings-permalinks-screen/">Documentation on Permalinks Settings</a>' ) . '</p>' .
+ '<p>' . __( '<a href="https://wordpress.org/support/article/using-permalinks/">Documentation on Using Permalinks</a>' ) . '</p>';
+
+if ( $is_nginx ) {
+ $help_sidebar_content .= '<p>' . __( '<a href="https://wordpress.org/support/article/nginx/">Documentation on Nginx configuration</a>.' ) . '</p>';
+}
+
+$help_sidebar_content .= '<p>' . __( '<a href="https://wordpress.org/support/">Support</a>' ) . '</p>';
+
+get_current_screen()->set_help_sidebar( $help_sidebar_content );
+unset( $help_sidebar_content );
$home_path = get_home_path();
$iis7_permalinks = iis7_supports_permalinks();
@@ -360,11 +367,12 @@
<p id="iis-description-a">
<?php
printf(
- /* translators: 1: web.config, 2: Documentation URL, 3: CTRL + a, 4: Element code. */
- __( 'If your %1$s file was <a href="%2$s">writable</a>, we could do this automatically, but it isn’t so this is the url rewrite rule you should have in your %1$s file. Click in the field and press %3$s to select all. Then insert this rule inside of the %4$s element in %1$s file.' ),
+ /* translators: 1: web.config, 2: Documentation URL, 3: Ctrl + A, 4: ⌘ + A, 5: Element code. */
+ __( '<strong>Error:</strong> Your %1$s file is not <a href="%2$s">writable</a>, so updating it automatically was not possible. This is the URL rewrite rule you should have in your %1$s file. Click in the field and press %3$s (or %4$s on Mac) to select all. Then insert this rule inside of the %5$s element in %1$s file.' ),
'<code>web.config</code>',
__( 'https://wordpress.org/support/article/changing-file-permissions/' ),
- '<kbd>CTRL + a</kbd>',
+ '<kbd>Ctrl + A</kbd>',
+ '<kbd>⌘ + A</kbd>',
'<code>/<configuration>/<system.webServer>/<rewrite>/<rules></code>'
);
?>
@@ -377,7 +385,7 @@
<?php
printf(
/* translators: %s: web.config */
- __( 'If you temporarily make your %s file writable for us to generate rewrite rules automatically, do not forget to revert the permissions after rule has been saved.' ),
+ __( 'If you temporarily make your %s file writable to generate rewrite rules automatically, do not forget to revert the permissions after the rule has been saved.' ),
'<code>web.config</code>'
);
?>
@@ -386,11 +394,12 @@
<p id="iis-description-b">
<?php
printf(
- /* translators: 1: Documentation URL, 2: web.config, 3: CTRL + a */
- __( 'If the root directory of your site was <a href="%1$s">writable</a>, we could do this automatically, but it isn’t so this is the url rewrite rule you should have in your %2$s file. Create a new file, called %2$s in the root directory of your site. Click in the field and press %3$s to select all. Then insert this code into the %2$s file.' ),
+ /* translators: 1: Documentation URL, 2: web.config, 3: Ctrl + A, 4: ⌘ + A */
+ __( '<strong>Error:</strong> The root directory of your site is not <a href="%1$s">writable</a>, so creating a file automatically was not possible. This is the URL rewrite rule you should have in your %2$s file. Create a new file called %2$s in the root directory of your site. Click in the field and press %3$s (or %4$s on Mac) to select all. Then insert this code into the %2$s file.' ),
__( 'https://wordpress.org/support/article/changing-file-permissions/' ),
'<code>web.config</code>',
- '<kbd>CTRL + a</kbd>'
+ '<kbd>Ctrl + A</kbd>',
+ '<kbd>⌘ + A</kbd>'
);
?>
</p>
@@ -402,27 +411,26 @@
<?php
printf(
/* translators: %s: web.config */
- __( 'If you temporarily make your site’s root directory writable for us to generate the %s file automatically, do not forget to revert the permissions after the file has been created.' ),
+ __( 'If you temporarily make your site’s root directory writable to generate the %s file automatically, do not forget to revert the permissions after the file has been created.' ),
'<code>web.config</code>'
);
?>
</p>
<?php endif; ?>
<?php endif; ?>
-<?php elseif ( $is_nginx ) : ?>
- <p><?php _e( '<a href="https://wordpress.org/support/article/nginx/">Documentation on Nginx configuration</a>.' ); ?></p>
- <?php
+ <?php
else :
if ( $permalink_structure && ! $using_index_permalinks && ! $writable && $htaccess_update_required ) :
?>
<p id="htaccess-description">
<?php
printf(
- /* translators: 1: .htaccess, 2: Documentation URL, 3: CTRL + a */
- __( 'If your %1$s file was <a href="%2$s">writable</a>, we could do this automatically, but it isn’t so these are the mod_rewrite rules you should have in your %1$s file. Click in the field and press %3$s to select all.' ),
+ /* translators: 1: .htaccess, 2: Documentation URL, 3: Ctrl + A, 4: ⌘ + A */
+ __( '<strong>Error:</strong> Your %1$s file is not <a href="%2$s">writable</a>, so updating it automatically was not possible. These are the mod_rewrite rules you should have in your %1$s file. Click in the field and press %3$s (or %4$s on Mac) to select all.' ),
'<code>.htaccess</code>',
__( 'https://wordpress.org/support/article/changing-file-permissions/' ),
- '<kbd>CTRL + a</kbd>'
+ '<kbd>Ctrl + A</kbd>',
+ '<kbd>⌘ + A</kbd>'
);
?>
</p>