Changeset 5777
- Timestamp:
- 07/04/2007 04:12:37 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-comments-post.php
r5707 r5777 1 1 <?php 2 if ( $_SERVER["REQUEST_METHOD"] != "POST") {3 4 header( "HTTP/1.1 405 Method Not Allowed");5 header( "Content-Type: text/plain");6 2 if ( 'POST' != $_SERVER['REQUEST_METHOD'] ) { 3 header('Allow: POST'); 4 header('HTTP/1.1 405 Method Not Allowed'); 5 header('Content-Type: text/plain'); 6 exit; 7 7 } 8 8 require( dirname(__FILE__) . '/wp-config.php' ); … … 64 64 65 65 $comment = get_comment($comment_id); 66 if ( !$user->ID ) :66 if ( !$user->ID ) { 67 67 setcookie('comment_author_' . COOKIEHASH, $comment->comment_author, time() + 30000000, COOKIEPATH, COOKIE_DOMAIN); 68 68 setcookie('comment_author_email_' . COOKIEHASH, $comment->comment_author_email, time() + 30000000, COOKIEPATH, COOKIE_DOMAIN); 69 69 setcookie('comment_author_url_' . COOKIEHASH, clean_url($comment->comment_author_url), time() + 30000000, COOKIEPATH, COOKIE_DOMAIN); 70 endif; 70 } 71 71 72 72 $location = ( empty($_POST['redirect_to']) ? get_permalink($comment_post_ID) : $_POST['redirect_to'] ) . '#comment-' . $comment_id;
Note: See TracChangeset
for help on using the changeset viewer.