Title: Issues with custom WP_CONTENT_DIR
Last modified: August 21, 2016

---

# Issues with custom WP_CONTENT_DIR

 *  Moderator [Dominik Schilling](https://wordpress.org/support/users/ocean90/)
 * (@ocean90)
 * WordPress Core Developer
 * [12 years, 8 months ago](https://wordpress.org/support/topic/issues-with-custom-wp_content_dir/)
 * Hey,
 * there are some notices related to a custom wp-content dir.
 *     ```
       Notice: Undefined offset: 1 in /srv/www/foo.dev/content/plugins/landing-pages/modules/module.post-type.php on line 149
   
       Notice: Undefined offset: 1 in /srv/www/foo.dev/content/plugins/landing-pages/modules/module.ab-testing.php on line 658
       ```
   
 * They are coming from
 *     ```
       $this_path = LANDINGPAGES_PATH;
       $this_path = explode('wp-content',$this_path);
       $this_path = "wp-content".$this_path[1];
       ```
   
 * This won’t work if you have something in wp-config.php like
    `define('WP_CONTENT_DIR',
   dirname(__FILE__) . '/content' );`
 * [http://wordpress.org/plugins/landing-pages/](http://wordpress.org/plugins/landing-pages/)

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

 *  Plugin Author [David Wells](https://wordpress.org/support/users/davidwells/)
 * (@davidwells)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/issues-with-custom-wp_content_dir/#post-4195462)
 * Do you know what the fix would be for this?
 * We haven’t run into this issue before
 *  Moderator [Dominik Schilling](https://wordpress.org/support/users/ocean90/)
 * (@ocean90)
 * WordPress Core Developer
 * [12 years, 8 months ago](https://wordpress.org/support/topic/issues-with-custom-wp_content_dir/#post-4195492)
 * It seems like this one [http://plugins.trac.wordpress.org/browser/landing-pages/trunk/modules/module.post-type.php#L146](http://plugins.trac.wordpress.org/browser/landing-pages/trunk/modules/module.post-type.php#L146)
   is even unused. (Also there is no need for is_admin() again, see line 115.)
    
   There is only a reference to the global here [http://plugins.trac.wordpress.org/browser/landing-pages/trunk/modules/module.post-type.php#L294](http://plugins.trac.wordpress.org/browser/landing-pages/trunk/modules/module.post-type.php#L294)

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

The topic ‘Issues with custom WP_CONTENT_DIR’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/landing-pages_88766e.svg)
 * [WordPress Landing Pages](https://wordpress.org/plugins/landing-pages/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/landing-pages/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/landing-pages/)
 * [Active Topics](https://wordpress.org/support/plugin/landing-pages/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/landing-pages/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/landing-pages/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [Dominik Schilling](https://wordpress.org/support/users/ocean90/)
 * Last activity: [12 years, 8 months ago](https://wordpress.org/support/topic/issues-with-custom-wp_content_dir/#post-4195492)
 * Status: not resolved