wordpress.patch 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. Index: wordpress/wp-includes/canonical.php
  2. --- wordpress/wp-includes/canonical.php.orig 2007-10-17 22:15:18 +0200
  3. +++ wordpress/wp-includes/canonical.php 2007-12-30 12:55:12 +0100
  4. @@ -108,6 +108,12 @@
  5. $user_home = @parse_url(get_option('home'));
  6. $redirect['host'] = $user_home['host'];
  7. + // SHAMELESS HACK TO MAKE WORDPRESS THINK IT IS RUNNING UNDER PORT 80
  8. + // TO FIX THE URL TROUBLE WITH THE USUAL FRONTEND APACHE WEBSERVER! --rse
  9. + $user_home['port'] = 80;
  10. + $redirect['port'] = 80;
  11. + $original['port'] = 80;
  12. +
  13. // Handle ports
  14. if ( isset($user_home['port']) )
  15. $redirect['port'] = $user_home['port'];
  16. Index: wordpress/wp-login.php
  17. --- wordpress/wp-login.php.orig 2007-09-26 01:17:30 +0200
  18. +++ wordpress/wp-login.php 2007-12-30 12:52:53 +0100
  19. @@ -115,7 +115,7 @@
  20. // Now insert the new pass md5'd into the db
  21. $wpdb->query("UPDATE $wpdb->users SET user_activation_key = '$key' WHERE user_login = '$user_login'");
  22. $message = __('Someone has asked to reset the password for the following site and username.') . "\r\n\r\n";
  23. - $message .= get_option('siteurl') . "\r\n\r\n";
  24. + $message .= sprintf(__('Website: %s'), get_option('siteurl')) . "\r\n";
  25. $message .= sprintf(__('Username: %s'), $user_login) . "\r\n\r\n";
  26. $message .= __('To reset your password visit the following address, otherwise just ignore this email and nothing will happen.') . "\r\n\r\n";
  27. $message .= get_option('siteurl') . "/wp-login.php?action=rp&key=$key\r\n";
  28. @@ -189,7 +189,7 @@
  29. wp_cache_delete($user->user_login, 'userlogins');
  30. $message = sprintf(__('Username: %s'), $user->user_login) . "\r\n";
  31. $message .= sprintf(__('Password: %s'), $new_pass) . "\r\n";
  32. - $message .= get_option('siteurl') . "/wp-login.php\r\n";
  33. + $message .= sprintf(__('Login: %s'), get_option('siteurl') . "/wp-login.php") . "\r\n";
  34. if (FALSE == wp_mail($user->user_email, sprintf(__('[%s] Your new password'), get_option('blogname')), $message)) {
  35. die('<p>' . __('The e-mail could not be sent.') . "<br />\n" . __('Possible reason: your host may have disabled the mail() function...') . '</p>');
  36. Index: wordpress/wp-mail.php
  37. --- wordpress/wp-mail.php.orig 2007-12-29 20:38:47 +0100
  38. +++ wordpress/wp-mail.php 2007-12-30 12:52:53 +0100
  39. @@ -142,7 +142,7 @@
  40. $post_category = $post_categories;
  41. // or maybe we should leave the choice to email drafts? propose a way
  42. - $post_status = 'publish';
  43. + $post_status = 'draft';
  44. $post_data = compact('post_content','post_title','post_date','post_date_gmt','post_author','post_category', 'post_status');
  45. $post_data = add_magic_quotes($post_data);