Title: [Plugin: WP Super Cache] wp-config.php &#8211; incorrect modification
Last modified: August 20, 2016

---

# [Plugin: WP Super Cache] wp-config.php – incorrect modification

 *  [Nic Windley](https://wordpress.org/support/users/nisiwi/)
 * (@nisiwi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/)
 * WP super cache is adding the;
 *     ```
       define('WP_CACHE', true); //Added by WP-Cache Manager
       ```
   
 * outside of the PHP block causing site errors every time I install it.
 * Yes I can manually modify it, however it would be nice if it inserted it inside
   the block or after the first php start code `<?php` at least.
 * Thanks!
 * [http://wordpress.org/extend/plugins/wp-super-cache/](http://wordpress.org/extend/plugins/wp-super-cache/)

Viewing 6 replies - 1 through 6 (of 6 total)

 *  [admintiger](https://wordpress.org/support/users/admintiger/)
 * (@admintiger)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649350)
 * That has not happened here. WP Super Cache inserted that line correctly in each
   of several installations.
 *  Thread Starter [Nic Windley](https://wordpress.org/support/users/nisiwi/)
 * (@nisiwi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649351)
 * OK admintiger, well I’ve just done another 10 installs and all with the same 
   result ?
 * Any suggestions and what could be causing this ?
 *  [admintiger](https://wordpress.org/support/users/admintiger/)
 * (@admintiger)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649352)
 * I haven’t looked at the code that writes that line in the wp-config.php file,
   but a non-standard wp-config.php file layout seems the most likely cause of the
   problem. Are there any lines above the <?php tag in that file. If so, move <?
   php to the beginning of the first line and see if that corrects the problem.
 *  [admintiger](https://wordpress.org/support/users/admintiger/)
 * (@admintiger)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649353)
 * Another thing to check is this line:
 * /** The name of the database for WordPress */
 * I don’t know, because I haven’t looked at the code, but I suspect the code searches
   for that line and then writes the following on the line below:
 *     ```
       define('WP_CACHE', true); //Added by WP-Cache Manager
       ```
   
 * If the text of that line has been changed, the line won’t be found and the software
   will be apt to write in a wrong place.
 * The top of the wp-config.php should be like this to avoid potential problems:
 * <?php
    /** * The base configurations of the WordPress. * * This file has the 
   following configurations: MySQL settings, Table Prefix, * Secret Keys, WordPress
   Language, and ABSPATH. You can find more information * by visiting {@link [http://codex.wordpress.org/Editing_wp-config.php](http://codex.wordpress.org/Editing_wp-config.php)
   Editing * wp-config.php} Codex page. You can get the MySQL settings from your
   web host. * * This file is used by the wp-config.php creation script during the*
   installation. You don’t have to use the web site, you can just copy this file*
   to “wp-config.php” and fill in the values. * * [@package](https://wordpress.org/support/users/package/)
   WordPress */
 * // ** MySQL settings – You can get this info from your web host ** //
    /** The
   name of the database for WordPress */
 *  Thread Starter [Nic Windley](https://wordpress.org/support/users/nisiwi/)
 * (@nisiwi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649354)
 * Strange…this is what I have, looks the same
 *     ```
       <?php
       /**
        * The base configurations of the WordPress.
        *
        * This file has the following configurations: MySQL settings, Table Prefix,
        * Secret Keys, WordPress Language, and ABSPATH. You can find more information
        * by visiting {@link http://codex.wordpress.org/Editing_wp-config.php Editing
        * wp-config.php} Codex page. You can get the MySQL settings from your web host.
        *
        * This file is used by the wp-config.php creation script during the
        * installation. You don't have to use the web site, you can just copy this file
        * to "wp-config.php" and fill in the values.
        *
        * @package WordPress
        */
   
       // ** MySQL settings - You can get this info from your web host ** //
   
       /** The name of the database for WordPress */
       ```
   
 *  Thread Starter [Nic Windley](https://wordpress.org/support/users/nisiwi/)
 * (@nisiwi)
 * [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649355)
 * Thanks for your advice admintiger.
 * I’ll have to check to make sure as its possible that the master code I’m using
   as a site template got modified somehow when it got zipped or just before.
 * If you think of anything else worth checking I’ll look at that also.
 * Thanks again!

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘[Plugin: WP Super Cache] wp-config.php – incorrect modification’ is closed
to new replies.

 * ![](https://ps.w.org/wp-super-cache/assets/icon-256x256.png?rev=3506220)
 * [WP Super Cache](https://wordpress.org/plugins/wp-super-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-super-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-super-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-super-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-super-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-super-cache/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [Nic Windley](https://wordpress.org/support/users/nisiwi/)
 * Last activity: [14 years, 1 month ago](https://wordpress.org/support/topic/plugin-wp-super-cache-wp-configphp-incorrect-modification/#post-2649355)
 * Status: not resolved