wp-comment-post.php error on $location
-
When posting a comment on my site, I hit “sumit” and get a php error that says:
Fatal error: Call to undefined function: wp_redirect() in /xxx/xxxx/wp-comments-post.php on line 59
I looked in the wp-comment-post.php and the code there says:
$location = (empty($_POST['redirect_to'])) ? $_SERVER["HTTP_REFERER"] : $_POST['redirect_to'];
wp_redirect($location);I’ve not altered this file in any way. The comment is submitted, but people are hitting the back button and resubmitting their comments, so I’m getting double comment postings.
Help?
Viewing 7 replies - 1 through 7 (of 7 total)
Viewing 7 replies - 1 through 7 (of 7 total)
- The topic ‘wp-comment-post.php error on $location’ is closed to new replies.