Support » Installing WordPress » WP 1.0.1 install-config.php problem & fix

  • It seems that a few lines of code are missing in the 1.0.1 version of install-config.php.
    This may be due to a change right before the foreach in line 121. It causes two problems:

    1. $configFile is undefined
    2. $handle is undefined

    I simply copied/inserted these lines from a previous version (was it 1.0?):
    if (!file_exists(‘../wp-config-sample.php’)) die(‘Sorry, I need a wp-config-sample.php file to work from. Please re-upload this file from your WordPress installation.’);
    $configFile = file(‘../wp-config-sample.php’);
    if (!is_writable(‘../’)) die(“Sorry, I can’t write to the directory. You’ll have to either change the permissions on your WordPress directory or create your wp-config.php manually.”);
    $handle = fopen(‘../wp-config.php’, ‘w’);
    Then the foreach works:
    foreach ($configFile as $line_num => $line) {
    switch (substr($line,0,16)) {
    And a note: It might be helpful for some people if install.php would say that the errors in the final step 3 of the process are during “final updates” and can be ignored. (Of course this was already said in this forum.)

Viewing 4 replies - 1 through 4 (of 4 total)
  • Why is this fix not yet in the CVS?! This got the install working for me on Mac OS X 10.3.

    where in the file am I supposed to put that missing code into install-config.php ?

    Moderator Matt Mullenweg



    This should be in the CVS now.

    Not quite. You caught the line to define $configFile, but you’re still missing the $handle = fopen('../wp-config.php', 'w'); so it still fails to write to an undefined handle.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.