WordPress.org

Make WordPress Core

Ticket #12670: htaccess.diff

File htaccess.diff, 1.5 KB (added by meheranandk, 4 years ago)
  • wp-config-sample.php

     
    3333/** The Database Collate type. Don't change this if in doubt. */ 
    3434define('DB_COLLATE', ''); 
    3535 
     36/** .htaccess filename. Change only if your webserver is using a different htaccess filename */ 
     37define('HTACCESS_NAME','.htaccess'); 
     38 
    3639/**#@+ 
    3740 * Authentication Unique Keys and Salts. 
    3841 * 
  • wp-admin/includes/misc.php

     
    126126        global $wp_rewrite; 
    127127 
    128128        $home_path = get_home_path(); 
    129         $htaccess_file = $home_path.'.htaccess'; 
     129        $htaccess_file = $home_path.HTACCESS_NAME; 
    130130 
    131131        // If the file doesn't already exist check for write access to the directory and whether we have some rules. 
    132132        // else check for write access to the file. 
  • wp-admin/options-permalink.php

     
    119119        else 
    120120                $writable = false; 
    121121} else { 
    122         if ( ( ! file_exists($home_path . '.htaccess') && is_writable($home_path) ) || is_writable($home_path . '.htaccess') ) 
     122        if ( ( ! file_exists($home_path . HTACCESS_NAME) && is_writable($home_path) ) || is_writable($home_path . HTACCESS_NAME) ) 
    123123                $writable = true; 
    124124        else 
    125125                $writable = false;