Title: failed to open stream?
Last modified: August 18, 2016

---

# failed to open stream?

 *  [weweblog](https://wordpress.org/support/users/weweblog/)
 * (@weweblog)
 * [22 years, 11 months ago](https://wordpress.org/support/topic/failed-to-open-stream/)
 * I want to install WordPress 0.71 gold.After I modified b2config.php in a text
   editor and uploaded everything,I Launched wp-install.php in your browser and 
   found the following error:
    Warning: main(//b2-include/wp-db.php): failed to 
   open stream: No such file or directory in E:\websites\musicool\program\php\b2config.
   php on line 337 Fatal error: main(): Failed opening required ‘//b2-include/wp-
   db.php’ (include_path=’.;c:\php4\pear’) in E:\websites\musicool\program\php\b2config.
   php on line 337 line 337? I didn’t modify it.What’s the problem?

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

 *  [coffeemike](https://wordpress.org/support/users/coffeemike/)
 * (@coffeemike)
 * [22 years, 11 months ago](https://wordpress.org/support/topic/failed-to-open-stream/#post-22629)
 * Check in the b2config.php file that your $siteurl does NOT end in a trailing /.
   That would be my first thought as to where the extra / is coming from.
 *  Thread Starter [weweblog](https://wordpress.org/support/users/weweblog/)
 * (@weweblog)
 * [22 years, 11 months ago](https://wordpress.org/support/topic/failed-to-open-stream/#post-22638)
 * Pls go to [http://weweblog.com/wp](http://weweblog.com/wp)
    In my b2config.php:
   $siteurl = ‘[http://weweblog.com/wp&#8217](http://weweblog.com/wp&#8217);; $blogfilename
   = ‘index.php’; $blogname = “Journalism and Communication”; $blogdescription =“
   babblings !”;
 *  125
 * [22 years, 11 months ago](https://wordpress.org/support/topic/failed-to-open-stream/#post-22641)
 * This has to do with the automatic generation of the path of WordPress which is
   done at the end of b2config.php. This doesn’t work if your WordPress directory
   isn’t under document root, e.g. if you’re using public_html directories. I’m 
   going to post a bug report for this in a second.
    In the meantime, you can fix
   it by changing the last few lines of b2config.php Change $abspath = getenv(‘DOCUMENT_ROOT’).
   $relpath . ‘/’; to $abspath = ‘full_path_to_wordpress_with_trailing_slash’ For
   example, $abspath = ‘/home/carlos/public_html/wordpress/’;
 *  Thread Starter [weweblog](https://wordpress.org/support/users/weweblog/)
 * (@weweblog)
 * [22 years, 11 months ago](https://wordpress.org/support/topic/failed-to-open-stream/#post-22644)
 * Thanks you very much.
    I have changed the code as you told me: $abspath = ‘/websites/
   musicool/program/php/wp/’; but now: Warning: Division by zero in E:\websites\
   musicool\program\php\wp\b2config.php on line 334 Warning: main(/b2-include/wp-
   db.php): failed to open stream: No such file or directory in E:\websites\musicool\
   program\php\wp\b2config.php on line 337 Fatal error: main(): Failed opening required‘/
   b2-include/wp-db.php’ (include_path=’.;c:\php4\pear’) in E:\websites\musicool\
   program\php\wp\b2config.php on line 337

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

The topic ‘failed to open stream?’ is closed to new replies.

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 4 replies
 * 3 participants
 * Last reply from: [weweblog](https://wordpress.org/support/users/weweblog/)
 * Last activity: [22 years, 11 months ago](https://wordpress.org/support/topic/failed-to-open-stream/#post-22644)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
