WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] 'Warning: main(./wp-blog-header.php)' error (12 posts)

  1. Herr_jensen
    Member
    Posted 5 years ago #

    Hey there,

    I'm currently installing version 2.5 of WP and it seems to be working... well sort of. The install process do not return any errors, I can login (as admin), view the dashboard, change skins but when I press the 'Visit Site' button I get this error:

    Warning: main(./wp-blog-header.php): failed to open stream: No such file or directory in d:\home\sydfynsautocamdk\www\index.php on line 4

    Fatal error: main(): Failed opening required './wp-blog-header.php' (include_path='.;c:\php4\pear') in d:\home\sydfynsautocamdk\www\index.php on line 4

    Dang.

    That means all visitors get that error message instead of the actual site when they drop by.

    I'm installing for a friend and I simply don't understand what I've done wrong. I did WP install on my own site (I use another hotel though) and it worked like a charm the first time. I really admire the WP install for it's simplicity so I'm a bit worried I managed to screw it up : /.

    Any help or pointers will be gratefully appreciated.

    Cheers,

    - Jensen

    PS: I've spend the last hour reading through many, many posts here but none of them seems to cover my particular error.

  2. Samuel B
    moderator
    Posted 5 years ago #

    /wp-blog-header.php
    wordpress is looking for that file
    make sure it is there and maybe re upload it anyway

  3. Herr_jensen
    Member
    Posted 5 years ago #

    wow, your fast.

    Thank you very much for your reply.

    Sadly the mentioned file is indeed there. I was wondering if the '.' just before the '/' could have any meaning?

    Warning: main(./wp-blog-header.php)
    ____________I
    ____________I
    That fella?

  4. Samuel B
    moderator
    Posted 5 years ago #

    require('./wp-blog-header.php');
    that is the line from index.php the error refers to - so that looks normal in your error above.
    Try uploading all of the core files again and /wp-content

    out of curiosity - why are you installing 2.5?

  5. Herr_jensen
    Member
    Posted 5 years ago #

    I'll try and upload the files again. Cheers.

    I install 2.5 because I tried the latest version first but it failed the install with the exact same error but before logging in to the dashboard. I read somewhere the latest version could create problems if the webhost server is not fully updated.

    : )

  6. Herr_jensen
    Member
    Posted 5 years ago #

    I tried deleting and uploading all the files again but it didn't work.

    I then tried to install 2.7.1 (I dropped the databases and deleted all the files). It installs but when I I'm about to login it comes with same error but now it's line 17 instead of line 4.

  7. chase117
    Member
    Posted 5 years ago #

    Same here,

  8. gaycheckml
    Member
    Posted 5 years ago #

    same here

  9. Herr_jensen
    Member
    Posted 5 years ago #

    It turned out it was because my webhotel wasn't running the latest PHP thingy.

    If you get this error check your hotel have the latest software installed.

  10. JessieBirks
    Member
    Posted 4 years ago #

    This post is a bit dusty, but it's the one that most closely matches my problem. I am getting the following error in my root directory:

    Warning: require(./wp-blog-header.php) [function.require]: failed to open stream: No such file or directory in D:\bikedenver\www\index.php on line 17

    Fatal error: require() [function.require]: Failed opening required './wp-blog-header.php' (include_path='.;C:\php5\pear') in D:\bikedenver\www\index.php on line 17

    This is a fresh install on a new host I just started working with. (I intend to migrate an existing WordPress site over, once I get this working.) I've followed their instructions for creating a database and uploading WordPress. I have tried this with both versions 2.9.1 and 2.8.1 of WordPress.

    The error is consistent. The admin area is accessible, but the front page throws this error. The only thing I am doing that's a little strange, is using an IP address instead of a URL.

    Any thoughts?

  11. Wulfrunner
    Member
    Posted 4 years ago #

    I've been fighting with this problem for a couple of hours, thinking that I somehow botched the move of one of my sites. It seemed strange, as I was able to successfully move it from my local server, then to a staging server without any trouble!

    Turns out that the problem is that I am moving from a Linux server to a Windows Web Hosting server where rivers flow uphill.

    Solution: Remove the "./"
    require('./wp-blog-header.php');

    Becomes
    require('wp-blog-header.php');

  12. JessieBirks
    Member
    Posted 4 years ago #

    Well, holy crap. That fixed it. Thanks, Wulfrunner.

    Are there any other files I need to modify? Is that really the only "require" call in the WordPress files?

Topic Closed

This topic has been closed to new replies.

About this Topic