Info
- 3 posts
- 2 voices
- Started 4 years ago by intellivision
- Latest reply from intellivision
- This topic is not resolved
Weird, bizarre problem with requiring wp-blog-header.php
-
- Posted 4 years ago #
require_once('../wp-blog-header.php'); ...With that I get no admin pages*.
require_once('../../wp-blog-header.php'); ...With that I get no non-admin pages**.
WP 2.3.2, bbPress 0.8.3.1, both are very fresh, no hacks etc.
WP is at http://dencx/wp, bbPress is at http://dencx/wp/forum/. I'm developing locally, as you can see by the url's.
$bb->uri = 'http://dencx/wp/forum/';
* = Warning: require_once(../wp-blog-header.php) [function.require-once]: failed to open stream: No such file or directory in /Users/matth/Sites/dencx/wp/forum/config.php on line 2
Fatal error: require_once() [function.require]: Failed opening required '../wp-blog-header.php' (include_path='.:') in /Users/matth/Sites/dencx/wp/forum/config.php on line 2
** = Warning: require_once(../../wp-blog-header.php) [function.require-once]: failed to open stream: No such file or directory in /Users/matth/Sites/dencx/wp/forum/config.php on line 2
Fatal error: require_once() [function.require]: Failed opening required '../../wp-blog-header.php' (include_path='.:') in /Users/matth/Sites/dencx/wp/forum/config.php on line 2
-
- Posted 4 years ago #
Well yeah, when you're in /wp-admin/ you're one folder deeper than when you're in the forum root. Use absolute not relative paths and you'll be fine.
-
- Posted 4 years ago #
Duh. Thanks fel. But I could have sworn relative pathing worked before for that require...
Anyway, I knew it was going to be something stupid while I was writing the above post. The weirder the problem, the stupider the mistake.
-
You must log in to post.