Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix ups.

git-svn-id: http://svn.automattic.com/wordpress/trunk@771 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information...
commit 5624ca0f6cc15b2f571b26377f289ffe0974c152 1 parent 8058390
saxmatt authored
Showing with 22 additions and 9 deletions.
  1. +1 −1  wp-admin/edit-form-comment.php
  2. +1 −1  wp-login.php
  3. +20 −7 wp-mail.php
View
2  wp-admin/edit-form-comment.php
@@ -100,5 +100,5 @@ function focusit() {
?>
</form>
-
+<p><a href="post.php?action=deletecomment&amp;noredir=true&amp;comment=<?php echo $commentdata['comment_ID']; ?>&amp;p=<?php echo $commentdata['comment_post_ID']; ?>">Delete this comment</a>.</p>
</div>
View
2  wp-login.php
@@ -200,7 +200,6 @@ function focusit() {
break;
-
case 'retrievepassword':
$user_login = $HTTP_POST_VARS["user_login"];
@@ -211,6 +210,7 @@ function focusit() {
if (!$user_email) die('Sorry, that user does not seem to exist in our database. Perhaps you have the wrong username?');
$message = "Login: $user_login\r\n";
$message .= "Password: $user_pass\r\n";
+ $message .= "Login at: $siteurl/wp-login.php";
$m = mail($user_email, "[$blogname] Your weblog's login/password", $message);
View
27 wp-mail.php
@@ -209,17 +209,18 @@
if ($user_level > 0) {
$post_title = xmlrpc_getposttitle($content);
- $post_category = xmlrpc_getpostcategory($content);
+ $post_categories[] = xmlrpc_getpostcategory($content);
if ($post_title == '') {
$post_title = $subject;
}
- if ($post_category == '') {
- $post_category = $default_category;
+ if (empty($post_categories)) {
+ $post_categories[] = $default_category;
}
if (!$thisisforfunonly) {
$post_title = addslashes(trim($post_title));
+ $content = preg_replace("|\n([^\n])|", " $1", $content);
$content = addslashes(trim($content));
if($flat > 500) {
$sql = "INSERT INTO $tableposts (post_author, post_date, post_content, post_title, post_category) VALUES ($post_author, '$post_date', '$content', '$post_title', $post_category)";
@@ -237,17 +238,29 @@
if($flat < 500) {
pingGeoUrl($post_ID);
}
- // HACK HACK HACK this next line is commented out because I don't know what the word-press replacement
- // is. right now it's undefined and does not work
- //rss_update($blog_ID);
+
pingWeblogs($blog_ID);
- pingCafelog($cafelogID, $post_title, $post_ID);
pingBlogs($blog_ID);
pingback($content, $post_ID);
}
echo "\n<p><b>Posted title:</b> $post_title<br />";
echo "\n<b>Posted content:</b><br /><pre>".$content.'</pre></p>';
+ if (!$post_categories) $post_categories[] = 1;
+ foreach ($post_categories as $post_category) {
+ // Double check it's not there already
+ $exists = $wpdb->get_row("SELECT * FROM $tablepost2cat WHERE post_id = $post_ID AND category_id = $post_category");
+
+ if (!$exists && $result) {
+ $wpdb->query("
+ INSERT INTO $tablepost2cat
+ (post_id, category_id)
+ VALUES
+ ($post_ID, $post_category)
+ ");
+ }
+ }
+
if(!$pop3->delete($iCount)) {
echo '<p>Oops '.$pop3->ERROR.'</p></div>';
$pop3->reset();
Please sign in to comment.
Something went wrong with that request. Please try again.