Support » Installing WordPress » upgrade to 2.6 – problems with pluggable.php line 1265

  • Resolved wordpress-notify



    I tried to update an existing WordPress installation from 2.5.1 to 2.6. After finishing and going to upgrade.php there was this error message:

    Parse error: syntax error, unexpected T_STRING in … /wp-includes/pluggable.php on line 1265

    I tried to make a brand new installation in a seperate folder with a new database and ended up with the same problem.

    Until the 2.6 update everything was fine since 2 years.

    Can somebody help resolving this?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Moderator Samuel Wood (Otto)

    (@otto42) Admin

    Bad copy of the pluggable.php file, perhaps?

    Redownload WordPress and re-upload the file.

    Thanks for the suggestion, but it didn’t work.

    What I now did is:

      upload aall new WP 2.6 files
      replaced pluggable.php (2.6) with pluggable.php (2.5.1)
      going to upgrade.php in the browser again

    It did work! I can now enter the Admin area again and could reactivate all the plugins which where deactivated before upgrading.

    After these things where successful, I tried to take the pluggable.php from the 2.6 installation package and copied it into the includes folder to replace the 2.5.1 version.

    What happend? Same mistake again. My Browser showed:

    Parse error: syntax error, unexpected T_STRING in ... /wp-includes/pluggable.php on line 1265

    So now I have a 2.6 installation with a pluggable.php that misses a lot (7KB) of new code.

    Line 1265 in pluggable.php is around the paragraph:

    // If the stored hash is longer than an MD5, presume the
    // new style phpass portable hash.
    if ( empty($wp_hasher) ) {
    	require_once( ABSPATH . 'wp-includes/class-phpass.php');
    		// By default, use the portable hash from phpass
    		$wp_hasher = new PasswordHash(8, TRUE);

    This has to do something with the new passwords and the responding information in wp-config.php, right?

    I don’t know what to do now.

    Moderator Samuel Wood (Otto)

    (@otto42) Admin

    I don’t know what to do now.

    Well, firstly, stop doing stupid things. You can’t just mix and match bits of code from different versions. That not only makes no sense, it will badly, BADLY break things in almost all cases.

    So for crying out loud, stop it. Never, ever, do that again.

    Next, make sure that you specifically uploaded ALL of the files. I’m thinking about new files, like class-phpass.php in the wp-includes directory.

    Hi Otto!

    At first: Thanks for your help!

    I know to mix versions is not a good idea! But at least I got my site to work again. I couldn’t even login before.

    Concerning the new files: I deleted EVERY file of the 2.5.1 version and afterwards copied the new version to the server. I did this more than once. – So – even if the server should have a “memory” 😉 it should be gone right now.

    And: yes the class-phpass.php is somehow involved in the problem – but Im not a programmer. I also thought about conflicts with the PHP installed on the server – but a friend of mine got the 2.6 version updated without any problem on the same webspace.

    Our provider did a database optimization using a automatic tool of php my-admin 2 weeks ago. Could it be this is confusing the WP-routines?


    Moderator Samuel Wood (Otto)

    (@otto42) Admin

    Could it be this is confusing the WP-routines?

    No. Not with that error.

    Something about your files is wrong. Maybe you uploaded them in binary instead of ascii mode in the FTP client? I don’t know for sure.

    Wow! That’s it!

    For 2 years I transfered the files in binary mode and there never was a problem. After your suggestion I switched to ASCII and copied the pluggable.php (2.6) to where it belongs and: YES! It works!

    Really crazy – there are so many things one has to know.

    A big Thank you to you!

    Moderator Samuel Wood (Otto)

    (@otto42) Admin

    Most FTP clients (try FileZilla) use an “auto” mode, where they pick the transfer mode based on the filetype.

    Text files *need* to be transferred in ASCII mode.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘upgrade to 2.6 – problems with pluggable.php line 1265’ is closed to new replies.