iis7_supports_permalinks example


function got_url_rewrite() {
    $got_url_rewrite = ( got_mod_rewrite() || $GLOBALS['is_nginx'] || iis7_supports_permalinks() );

    /** * Filters whether URL rewriting is available. * * @since 3.7.0 * * @param bool $got_url_rewrite Whether URL rewriting is available. */
    return apply_filters( 'got_url_rewrite', $got_url_rewrite );
}


            ?> <?php _e( 'To make your installation more secure, you should also add:' ); ?> </p> <p class="configuration-rules-label"><label for="network-wpconfig-authentication"><?php _e( 'Network configuration authentication keys' ); ?></label></p> <textarea id="network-wpconfig-authentication" class="code" readonly="readonly" cols="100" rows="<?php echo $num_keys_salts; ?>" aria-describedby="network-wpconfig-authentication-description"><?php echo esc_textarea( $keys_salts_str ); ?></textarea> <?php         }
        ?> </li> <?php     if ( iis7_supports_permalinks() ) :
        // IIS doesn't support RewriteBase, all your RewriteBase are belong to us.         $iis_subdir_match       = ltrim( $base, '/' ) . $subdir_match;
        $iis_rewrite_base       = ltrim( $base, '/' ) . $rewrite_base;
        $iis_subdir_replacement = $subdomain_install ? '' : '{R:1}';

        $web_config_file = '<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <rewrite> <rules> <rule name="WordPress Rule 1" stopProcessing="true"> <match url="^index\.php$" ignoreCase="false" /> <action type="None" /> </rule>';

    if ( is_preview() && get_query_var( 'p' ) && 'publish' === get_post_status( get_query_var( 'p' ) ) ) {
        if ( ! isset( $_GET['preview_id'] )
            || ! isset( $_GET['preview_nonce'] )
            || ! wp_verify_nonce( $_GET['preview_nonce'], 'post_preview_' . (int) $_GET['preview_id'] )
        ) {
            $wp_query->is_preview = false;
        }
    }

    if ( is_admin() || is_search() || is_preview() || is_trackback() || is_favicon()
        || ( $is_IIS && ! iis7_supports_permalinks() )
    ) {
        return;
    }

    if ( ! $requested_url && isset( $_SERVER['HTTP_HOST'] ) ) {
        // Build the URL in the address bar.         $requested_url  = is_ssl() ? 'https://' : 'http://';
        $requested_url .= $_SERVER['HTTP_HOST'];
        $requested_url .= $_SERVER['REQUEST_URI'];
    }

    
if ( $is_nginx ) {
    $help_sidebar_content .= '<p>' . __( '<a href="https://wordpress.org/documentation/article/nginx/">Documentation on Nginx configuration</a>.' ) . '</p>';
}

$help_sidebar_content .= '<p>' . __( '<a href="https://wordpress.org/support/forums/">Support forums</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();
$permalink_structure = get_option( 'permalink_structure' );

$index_php_prefix = '';
$blog_prefix      = '';

if ( ! got_url_rewrite() ) {
    $index_php_prefix = '/index.php';
}

/* * In a subdirectory configuration of multisite, the `/blog` prefix is used by * default on the main site to avoid collisions with other sites created on that * network. If the `permalink_structure` option has been changed to remove this * base prefix, WordPress core can no longer account for the possible collision. */
Home | Imprint | This part of the site doesn't use cookies.