Securing WordPress 2 Admin Access With SSL
See http://blog.blackdown.de/2006/01/22/securing-wordpress-2-admin-access-with-ssl/

wp2-ssl.patch (by Juergen Kreileder <jk@blackdown.de>):

* Use secure authentication cookies in wp_setcookie()
* Make check_admin_referer() work with HTTPS URLs
* Use HTTPS URLs for notification mails
* Use HTTPS URLS for redirects to wp-login.php
* Only allow login over XML-RPC if request comes from the local
  host (ie. the HTTPS proxy)
* Backport 'Mark-as-Spam' feature from trunk

Changelog:

2007-01-12      Update for WordPress 2.0.6 and 2.0.7-RC1
2006-07-29      * Updated for WordPress 2.0.4
2006-06-01      * Updated for WordPress 2.0.3
                * Removed patches included upstream
                * Allow XML-RPC login from the local host
                * More 'Mark-as-Spam'
2006-03-19      * Set content type for list-manipulation.php output
                * Use HTTPS for Login & Register links
                * Backport 'Mark-as-Spam' feature from trunk
2006-02-01      Updated for WordPress 2.0.1
2006-01-22      Initial version


=== wordpress/wp-includes/template-functions-general.php
==================================================================
--- wordpress/wp-includes/template-functions-general.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-includes/template-functions-general.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -28,9 +28,9 @@
 
 function wp_loginout() {
 	if ( ! is_user_logged_in() )
-		$link = '<a href="' . get_settings('siteurl') . '/wp-login.php">' . __('Login') . '</a>';
+		$link = '<a href="' . preg_replace('/^http/', 'https', get_settings('siteurl')) . '/wp-login.php">' . __('Login') . '</a>';
 	else
-		$link = '<a href="' . get_settings('siteurl') . '/wp-login.php?action=logout">' . __('Logout') . '</a>';
+		$link = '<a href="' . preg_replace('/^http/', 'https', get_settings('siteurl')) . '/wp-login.php?action=logout">' . __('Logout') . '</a>';
 
 	echo apply_filters('loginout', $link);
 }
@@ -40,11 +40,11 @@
 
 	if ( ! is_user_logged_in() ) {
 		if ( get_settings('users_can_register') )
-			$link = $before . '<a href="' . get_settings('siteurl') . '/wp-register.php">' . __('Register') . '</a>' . $after;
+			$link = $before . '<a href="' . preg_replace('/^http/', 'https', get_settings('siteurl')) . '/wp-register.php">' . __('Register') . '</a>' . $after;
 		else
 			$link = '';
 	} else {
-		$link = $before . '<a href="' . get_settings('siteurl') . '/wp-admin/">' . __('Site Admin') . '</a>' . $after;
+		$link = $before . '<a href="' . preg_replace('/^http/', 'https', get_settings('siteurl')) . '/wp-admin/">' . __('Site Admin') . '</a>' . $after;
 	}
 
 	echo apply_filters('register', $link);
=== wordpress/wp-includes/pluggable-functions.php
==================================================================
--- wordpress/wp-includes/pluggable-functions.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-includes/pluggable-functions.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -217,7 +218,7 @@
 			 (empty($_COOKIE[USER_COOKIE])) ) {
 		nocache_headers();
 	
-		wp_redirect(get_settings('siteurl') . '/wp-login.php?redirect_to=' . urlencode($_SERVER['REQUEST_URI']));
+		wp_redirect(preg_replace('/^http/', 'https', get_settings('siteurl')) . '/wp-login.php?redirect_to=' . urlencode($_SERVER['REQUEST_URI']));
 		exit();
 	}
 }
@@ -225,7 +226,7 @@
 
 if ( !function_exists('check_admin_referer') ) :
 function check_admin_referer($action = -1) {
-	$adminurl = strtolower(get_settings('siteurl')).'/wp-admin';
+	$adminurl = preg_replace('/^http/', 'https', strtolower(get_settings('siteurl'))).'/wp-admin';
 	$referer = strtolower(wp_get_referer());
 	if ( !wp_verify_nonce($_REQUEST['_wpnonce'], $action) &&
 		!(-1 == $action && strstr($referer, $adminurl)) ) {
@@ -305,22 +306,22 @@
 	else
 		$expire = 0;
 
-	setcookie(USER_COOKIE, $username, $expire, $cookiepath, COOKIE_DOMAIN);
-	setcookie(PASS_COOKIE, $password, $expire, $cookiepath, COOKIE_DOMAIN);
+	setcookie(USER_COOKIE, $username, $expire, $cookiepath, COOKIE_DOMAIN, 1);
+	setcookie(PASS_COOKIE, $password, $expire, $cookiepath, COOKIE_DOMAIN, 1);
 
 	if ( $cookiepath != $sitecookiepath ) {
-		setcookie(USER_COOKIE, $username, $expire, $sitecookiepath, COOKIE_DOMAIN);
-		setcookie(PASS_COOKIE, $password, $expire, $sitecookiepath, COOKIE_DOMAIN);
+		setcookie(USER_COOKIE, $username, $expire, $sitecookiepath, COOKIE_DOMAIN, 1);
+		setcookie(PASS_COOKIE, $password, $expire, $sitecookiepath, COOKIE_DOMAIN, 1);
 	}
 }
 endif;
 
 if ( !function_exists('wp_clearcookie') ) :
 function wp_clearcookie() {
-	setcookie(USER_COOKIE, ' ', time() - 31536000, COOKIEPATH, COOKIE_DOMAIN);
-	setcookie(PASS_COOKIE, ' ', time() - 31536000, COOKIEPATH, COOKIE_DOMAIN);
-	setcookie(USER_COOKIE, ' ', time() - 31536000, SITECOOKIEPATH, COOKIE_DOMAIN);
-	setcookie(PASS_COOKIE, ' ', time() - 31536000, SITECOOKIEPATH, COOKIE_DOMAIN);
+	setcookie(USER_COOKIE, ' ', time() - 31536000, COOKIEPATH, COOKIE_DOMAIN, 1);
+	setcookie(PASS_COOKIE, ' ', time() - 31536000, COOKIEPATH, COOKIE_DOMAIN, 1);
+	setcookie(USER_COOKIE, ' ', time() - 31536000, SITECOOKIEPATH, COOKIE_DOMAIN, 1);
+	setcookie(PASS_COOKIE, ' ', time() - 31536000, SITECOOKIEPATH, COOKIE_DOMAIN, 1);
 }
 endif;
 
@@ -365,7 +366,8 @@
 		$subject = sprintf( __('[%1$s] Pingback: "%2$s"'), $blogname, $post->post_title );
 	}
 	$notify_message .= get_permalink($comment->comment_post_ID) . "#comments\r\n\r\n";
-	$notify_message .= sprintf( __('To delete this comment, visit: %s'), get_settings('siteurl').'/wp-admin/post.php?action=confirmdeletecomment&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
+	$notify_message .= sprintf( __('To delete this comment, visit: %s'), preg_replace('/^http/', 'https', get_settings('siteurl')).'/wp-admin/post.php?action=confirmdeletecomment&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
+	$notify_message .= sprintf( __('To mark this comment as spam, visit: %s'), preg_replace('/^http/', 'https', get_settings('siteurl')).'/wp-admin/post.php?action=confirmdeletecomment&delete_type=spam&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
 
 	$wp_email = 'wordpress@' . preg_replace('#^www\.#', '', strtolower($_SERVER['SERVER_NAME']));
 
@@ -421,10 +423,11 @@
 	$notify_message .= sprintf( __('URI    : %s'), $comment->comment_author_url ) . "\r\n";
 	$notify_message .= sprintf( __('Whois  : http://ws.arin.net/cgi-bin/whois.pl?queryinput=%s'), $comment->comment_author_IP ) . "\r\n";
 	$notify_message .= __('Comment: ') . "\r\n" . $comment->comment_content . "\r\n\r\n";
-	$notify_message .= sprintf( __('To approve this comment, visit: %s'),  get_settings('siteurl').'/wp-admin/post.php?action=mailapprovecomment&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
-	$notify_message .= sprintf( __('To delete this comment, visit: %s'), get_settings('siteurl').'/wp-admin/post.php?action=confirmdeletecomment&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
+	$notify_message .= sprintf( __('To approve this comment, visit: %s'),  preg_replace('/^http/', 'https', get_settings('siteurl')).'/wp-admin/post.php?action=mailapprovecomment&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
+	$notify_message .= sprintf( __('To delete this comment, visit: %s'), preg_replace('/^http/', 'https', get_settings('siteurl')).'/wp-admin/post.php?action=confirmdeletecomment&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
+	$notify_message .= sprintf( __('To mark this comment as spam, visit: %s'), preg_replace('/^http/', 'https', get_settings('siteurl')).'/wp-admin/post.php?action=confirmdeletecomment&delete_type=spam&p='.$comment->comment_post_ID."&comment=$comment_id" ) . "\r\n";
 	$notify_message .= sprintf( __('Currently %s comments are waiting for approval. Please visit the moderation panel:'), $comments_waiting ) . "\r\n";
-	$notify_message .= get_settings('siteurl') . "/wp-admin/moderation.php\r\n";
+	$notify_message .= preg_replace('/^http/', 'https', get_settings('siteurl')) . "/wp-admin/moderation.php\r\n";
 
 	$subject = sprintf( __('[%1$s] Please moderate: "%2$s"'), get_settings('blogname'), $post->post_title );
 	$admin_email = get_settings('admin_email');
@@ -456,7 +459,7 @@
 
 	$message  = sprintf(__('Username: %s'), $user_login) . "\r\n";
 	$message .= sprintf(__('Password: %s'), $plaintext_pass) . "\r\n";
-	$message .= get_settings('siteurl') . "/wp-login.php\r\n";
+	$message .= preg_replace('/^http/', 'https', get_settings('siteurl')) . "/wp-login.php\r\n";
 		
 	wp_mail($user_email, sprintf(__('[%s] Your username and password'), get_settings('blogname')), $message);
 	

=== wordpress/xmlrpc.php
==================================================================
--- wordpress/xmlrpc.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/xmlrpc.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -124,11 +124,14 @@
 	}
 
 	function login_pass_ok($user_login, $user_pass) {
-	  if (!user_pass_ok($user_login, $user_pass)) {
-	    $this->error = new IXR_Error(403, 'Bad login/pass combination.');
+	  if (!isset($_SERVER['REMOTE_ADDR']) ||
+	      !isset($_SERVER['SERVER_ADDR']) ||
+	      $_SERVER['REMOTE_ADDR'] != $_SERVER['SERVER_ADDR'] ||
+	      !user_pass_ok($user_login, $user_pass)) {
+	    $this->error = new IXR_Error(403, 'Go away!');
 	    return false;
-	  }
-	  return true;
+ 	  }
+ 	  return true;
 	}
 
 	function escape(&$array) {
=== wordpress/wp-admin/edit-comments.php
==================================================================
--- wordpress/wp-admin/edit-comments.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-admin/edit-comments.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -45,13 +45,21 @@
 	foreach ($_POST['delete_comments'] as $comment) : // Check the permissions on each
 		$comment = (int) $comment;
 		$post_id = $wpdb->get_var("SELECT comment_post_ID FROM $wpdb->comments WHERE comment_ID = $comment");
-		$authordata = get_userdata( $wpdb->get_var("SELECT post_author FROM $wpdb->posts WHERE ID = $post_id") );
-		if ( current_user_can('edit_post', $post_id) ) :
-			wp_set_comment_status($comment, "delete");
+		// $authordata = get_userdata( $wpdb->get_var("SELECT post_author FROM $wpdb->posts WHERE ID = $post_id") );
+		if ( current_user_can('edit_post', $post_id) ) {
+			if ( !empty( $_POST['spam_button'] ) )
+				wp_set_comment_status($comment, "spam");
+			else
+				wp_set_comment_status($comment, "delete");
 			++$i;
-		endif;
+		}
 	endforeach;
-	echo "<div class='wrap'><p>" . sprintf(__('%s comments deleted.'), $i) . "</p></div>";
+	echo '<div style="background-color: rgb(207, 235, 247);" id="message" class="updated fade"><p>';
+	if ( !empty( $_POST['spam_button'] ) )
+		printf(__('%s comments marked as spam.'), $i);
+	else
+		printf(__('%s comments deleted.'), $i);
+	echo '</p></div>';
 endif;
 
 if (isset($_GET['s'])) {
@@ -98,7 +106,8 @@
         <p><?php _e('Posted'); echo ' '; comment_date('M j, g:i A');  
 			if ( current_user_can('edit_post', $comment->comment_post_ID) ) {
 				echo " | <a href=\"post.php?action=editcomment&amp;comment=".$comment->comment_ID."\">" . __('Edit Comment') . "</a>";
-				echo ' | <a href="' . wp_nonce_url('post.php?action=deletecomment&amp;p=' . $comment->comment_post_ID . '&amp;comment=' . $comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . '" onclick="return deleteSomething( \'comment\', ' . $comment->comment_ID . ', \'' . __("You are about to delete this comment.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to delete.") . "' );\">" . __('Delete Comment') . '</a> ';
+				echo ' | <a href="' . wp_nonce_url('post.php?action=deletecomment&amp;p=' . $comment->comment_post_ID . '&amp;comment=' . $comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . '" onclick="return deleteSomething( \'comment\', ' . $comment->comment_ID . ', \'' . __("You are about to delete this comment.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to delete.") . "' );\">" . __('Delete Comment') . '</a>';
+				echo ' | <a href="' . wp_nonce_url('post.php?action=deletecomment&amp;delete_type=spam&amp;p=' . $comment->comment_post_ID . '&amp;comment=' . $comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . '" onclick="return deleteSomething( \'comment-as-spam\', ' . $comment->comment_ID . ', \'' . __("You are about to mark this comment as spam.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to mark as spam.") . "' );\">" . __('Mark Comment as Spam') . '</a> ';
 			} // end if any comments to show
 			// Get post title
 			if ( current_user_can('edit_post', $comment->comment_post_ID) ) {
@@ -152,12 +161,15 @@
 	echo "<a href='post.php?action=editcomment&amp;comment=$comment->comment_ID' class='edit'>" .  __('Edit') . "</a>"; } ?></td>
     <td><?php if ( current_user_can('edit_post', $comment->comment_post_ID) ) {
             echo "<a href=\"" . wp_nonce_url("post.php?action=deletecomment&amp;p=".$comment->comment_post_ID."&amp;comment=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return confirm('" . __("You are about to delete this comment.\\n  \'Cancel\' to stop, \'OK\' to delete.") . "')\"    class='delete'>" . __('Delete') . "</a>"; } ?></td>
+    <td><?php if ( current_user_can('edit_post', $comment->comment_post_ID) ) {
+            echo "<a href=\"" . wp_nonce_url("post.php?action=deletecomment&amp;delete_type=spam&amp;p=".$comment->comment_post_ID."&amp;comment=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return confirm('" . __("You are about to mark this comment as spam.\\n  \'Cancel\' to stop, \'OK\' to mark as spam.") . "')\"    class='delete'>" . __('Spam') . "</a>"; } ?></td>
   </tr>
 		<?php 
 		} // end foreach
 	?></table>
     <p><a href="javascript:;" onclick="checkAll(document.getElementById('deletecomments')); return false; "><?php _e('Invert Checkbox Selection') ?></a></p>
-            <p class="submit"><input type="submit" name="Submit" value="<?php _e('Delete Checked Comments') ?> &raquo;" onclick="return confirm('<?php _e("You are about to delete these comments permanently.\\n  \'Cancel\' to stop, \'OK\' to delete.") ?>')" />	</p>
+            <p class="submit"><input type="submit" name="delete_button" value="<?php _e('Delete Checked Comments') ?> &raquo;" onclick="return confirm('<?php _e("You are about to delete these comments permanently.\\n  \'Cancel\' to stop, \'OK\' to delete.") ?>')" />
+			<input type="submit" name="spam_button" value="<?php _e('Mark Checked Comments as Spam') ?> &raquo;" onclick="return confirm('<?php _e("You are about to mark these comments as spam.\\n  \'Cancel\' to stop, \'OK\' to mark as spam.") ?>')" /></p>
   </form>
 <?php
 	} else {
=== wordpress/wp-admin/list-manipulation.php
==================================================================
--- wordpress/wp-admin/list-manipulation.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-admin/list-manipulation.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -63,6 +63,20 @@
 		die('0');
 	}
 	break;
+case 'delete-comment-as-spam' :
+	$id = (int) $_POST['id'];
+
+	if ( !$comment = get_comment($id) )
+		die('0');
+	if ( !current_user_can('edit_post', $comment->comment_post_ID) )
+		die('-1');
+
+	if ( wp_set_comment_status($comment->comment_ID, 'spam') ) {
+		die('1');
+	} else {
+		die('0');
+	}
+	break;
 case 'delete-link-category' :
 	$id = (int) $_POST['id'];
 	if ( 1 == $id )

=== wordpress/wp-admin/edit.php
==================================================================
--- wordpress/wp-admin/edit.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-admin/edit.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -271,6 +271,7 @@
 						echo ' - <a href="' . wp_nonce_url('post.php?action=approvecomment&amp;p=' . $post->ID . '&amp;comment=' . $comment->comment_ID, 'approve-comment_' . $comment->comment_ID) . '">' . __('Approve') . '</a> ';
 					}
 				}
+				echo ' - <a href="' . wp_nonce_url('post.php?action=deletecomment&amp;delete_type=spam&amp;p=' . $post->ID . '&amp;comment=' . $comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . '" onclick="return confirm(\'' . __("You are about to mark this comment as spam.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to mark as spam.") . "');\">" . __('Spam') . '</a> ';
 				echo "]";
 			} // end if any comments to show
 			?> 
=== wordpress/wp-admin/post.php
==================================================================
--- wordpress/wp-admin/post.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-admin/post.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -201,7 +201,10 @@
 		die( __('You are not allowed to delete comments on this post.') );
 
 	echo "<div class='wrap'>\n";
-	echo "<p>" . __('<strong>Caution:</strong> You are about to delete the following comment:') . "</p>\n";
+	if ( 'spam' == $_GET['delete_type'] )
+		echo "<p>" . __('<strong>Caution:</strong> You are about to mark the following comment as spam:') . "</p>\n";
+	else
+		echo "<p>" . __('<strong>Caution:</strong> You are about to delete the following comment:') . "</p>\n";
 	echo "<table border='0'>\n";
 	echo "<tr><td>" . __('Author:') . "</td><td>$comment->comment_author</td></tr>\n";
 	echo "<tr><td>" . __('E-mail:') . "</td><td>$comment->comment_author_email</td></tr>\n";
@@ -212,6 +215,8 @@
 
 	echo "<form action='".get_settings('siteurl')."/wp-admin/post.php' method='get'>\n";
 	echo "<input type='hidden' name='action' value='deletecomment' />\n";
+	if ( 'spam' == $_GET['delete_type'] )
+		echo "<input type='hidden' name='delete_type' value='spam' />\n";
 	echo "<input type='hidden' name='p' value='$p' />\n";
 	echo "<input type='hidden' name='comment' value='{$comment->comment_ID}' />\n";
 	echo "<input type='hidden' name='noredir' value='1' />\n";
@@ -243,8 +248,10 @@
 	if ( !current_user_can('edit_post', $comment->comment_post_ID) )	
 		die( __('You are not allowed to edit comments on this post.') );
 
-	wp_set_comment_status($comment->comment_ID, "delete");
-	do_action('delete_comment', $comment->comment_ID);
+	if ( 'spam' == $_GET['delete_type'] )
+		wp_set_comment_status($comment->comment_ID, 'spam');
+	else
+		wp_delete_comment($comment->comment_ID);
 
 	if ((wp_get_referer() != "") && (false == $noredir)) {
 		wp_redirect(wp_get_referer());
=== wordpress/wp-admin/list-manipulation.js
==================================================================
--- wordpress/wp-admin/list-manipulation.js	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-admin/list-manipulation.js	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -32,7 +32,7 @@
 	ajaxDel.onLoading = function() { ajaxDel.myResponseElement.innerHTML = 'Sending Data...'; };
 	ajaxDel.onLoaded = function() { ajaxDel.myResponseElement.innerHTML = 'Data Sent...'; };
 	ajaxDel.onInteractive = function() { ajaxDel.myResponseElement.innerHTML = 'Processing Data...'; };
-	ajaxDel.onCompletion = function() { removeThisItem( what + '-' + id ); };
+	ajaxDel.onCompletion = function() { removeThisItem( what.replace('-as-spam', '') + '-' + id ); };
 	ajaxDel.runAJAX('action=delete-' + what + '&id=' + id + '&' + ajaxDel.encVar('cookie', document.cookie));
 	return false;
 }
=== wordpress/wp-admin/moderation.php
==================================================================
--- wordpress/wp-admin/moderation.php	(/wordpress/branches/wordpress-2.0)	(revision 6420)
+++ wordpress/wp-admin/moderation.php	(/wordpress/branches/jk-2.0)	(revision 6420)
@@ -151,7 +151,8 @@
 echo '<a href="post.php?action=editcomment&amp;comment='.$comment->comment_ID.'">' . __('Edit') . '</a> | ';?>
 <a href="<?php echo get_permalink($comment->comment_post_ID); ?>"><?php _e('View Post') ?></a> | 
 <?php 
-echo " <a href=\"" . wp_nonce_url("post.php?action=deletecomment&amp;p=".$comment->comment_post_ID."&amp;comment=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return deleteSomething( 'comment', $comment->comment_ID, '" . __("You are about to delete this comment.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to delete.") . "' );\">" . __('Delete just this comment') . "</a> | "; ?>  <?php _e('Bulk action:') ?>
+echo " <a href=\"" . wp_nonce_url("post.php?action=deletecomment&amp;p=".$comment->comment_post_ID."&amp;comment=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return deleteSomething( 'comment', $comment->comment_ID, '" . __("You are about to delete this comment.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to delete.") . "' );\">" . __('Delete just this comment') . "</a> | ";
+echo " <a href=\"" . wp_nonce_url("post.php?action=deletecomment&apm;delete_type=spam&amp;p=".$comment->comment_post_ID."&amp;comment=".$comment->comment_ID, 'delete-comment_' . $comment->comment_ID) . "\" onclick=\"return deleteSomething( 'comment-as-spam', $comment->comment_ID, '" . __("You are about to mark this comment as spam.\\n&quot;Cancel&quot; to stop, &quot;OK&quot; to mark as spam.") . "' );\">" . __('Mark just this comment as spam') . "</a> | "; ?>  <?php _e('Bulk action:') ?>
 	<input type="radio" name="comment[<?php echo $comment->comment_ID; ?>]" id="comment-<?php echo $comment->comment_ID; ?>-approve" value="approve" /> <label for="comment-<?php echo $comment->comment_ID; ?>-approve"><?php _e('Approve') ?></label>
 	<input type="radio" name="comment[<?php echo $comment->comment_ID; ?>]" id="comment-<?php echo $comment->comment_ID; ?>-spam" value="spam" /> <label for="comment-<?php echo $comment->comment_ID; ?>-spam"><?php _e('Spam') ?></label>
 	<input type="radio" name="comment[<?php echo $comment->comment_ID; ?>]" id="comment-<?php echo $comment->comment_ID; ?>-delete" value="delete" /> <label for="comment-<?php echo $comment->comment_ID; ?>-delete"><?php _e('Delete') ?></label>
