Title: wp config create uses outdated data
Last modified: June 15, 2021

---

# wp config create uses outdated data

 *  [masyia](https://wordpress.org/support/users/masyia/)
 * (@masyia)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/wp-config-create-uses-outdated-data/)
 * Hello,
 * I downloaded latest WP files and then run `wp config create` to generate wp-config.
   php. I noticed that generated wp-config.php has following lines:
 *     ```
       /** Absolute path to the WordPress directory. */
       if ( ! defined( 'ABSPATH' ) ) {
               define( 'ABSPATH', dirname( __FILE__ ) . '/' );
       }
       ```
   
 * While wp-config-sample.php has:
 *     ```
       /** Absolute path to the WordPress directory. */
       if ( ! defined( 'ABSPATH' ) ) {
               define( 'ABSPATH', __DIR__ . '/' );
       }
       ```
   
 * I found that change from “FILE” to “DIR” was implemented in [this commit](https://github.com/WordPress/WordPress/commit/47ed56f38ff85423c82642fa3a19b0948bf5b6a4#diff-822b48f02be2502a07bf8274bc90a24d00c90cd27de717860d2f8195caa19577)
 * But wp-cli seem still uses old template.
 * I use latest wp-cli version:
 *     ```
       wp --info
       PHP version:    7.4.12
       WP-CLI root dir:        phar://wp-cli.phar/vendor/wp-cli/wp-cli
       WP-CLI vendor dir:      phar://wp-cli.phar/vendor
       WP_CLI phar path:       /var/www/html
       WP-CLI packages dir:
       WP-CLI global config:
       WP-CLI project config:
       WP-CLI version: 2.5.0
       ```
   
 * While that does not seem to affect website work, it feels incorrect to have all
   core files updated to “DIR”, but have “FILE” in wp-config.php. Please advise.
    -  This topic was modified 4 years, 11 months ago by [Yui](https://wordpress.org/support/users/fierevere/).
    -  This topic was modified 4 years, 11 months ago by [Jan Dembowski](https://wordpress.org/support/users/jdembowski/).
      Reason: Moved to Fixing WordPress, this is not a Requests and Feedback topic

Viewing 1 replies (of 1 total)

 *  Moderator [t-p](https://wordpress.org/support/users/t-p/)
 * (@t-p)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/wp-config-create-uses-outdated-data/#post-14559300)
 * Found a bug? Create a ticket in our [bug tracker](https://wordpress.org/support/bb-login.php?redirect_to=https://core.trac.wordpress.org/newticket).

Viewing 1 replies (of 1 total)

The topic ‘wp config create uses outdated data’ is closed to new replies.

## Tags

 * [wp-cli](https://wordpress.org/support/topic-tag/wp-cli/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [t-p](https://wordpress.org/support/users/t-p/)
 * Last activity: [4 years, 11 months ago](https://wordpress.org/support/topic/wp-config-create-uses-outdated-data/#post-14559300)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
