Commit 3d13a385 authored by Dries's avatar Dries

- Patch #36727 by Goba: fixed incorrect use of drupal_goto().

parent 3768616a
...@@ -348,7 +348,7 @@ function comment_reply($nid, $pid = NULL) { ...@@ -348,7 +348,7 @@ function comment_reply($nid, $pid = NULL) {
return comment_preview($edit); return comment_preview($edit);
} }
else { else {
drupal_goto("node/$nid#comment-$cid"); drupal_goto("node/$nid", NULL, "comment-$cid");
} }
} }
else if ($_POST['op'] == t('Preview comment')) { else if ($_POST['op'] == t('Preview comment')) {
...@@ -548,7 +548,7 @@ function comment_save($edit) { ...@@ -548,7 +548,7 @@ function comment_save($edit) {
if ($edit['cid']) { if ($edit['cid']) {
// Update the comment in the database. // Update the comment in the database.
db_query("UPDATE {comments} SET status = '%s', timestamp = '%d', subject = '%s', comment = '%s', format = '%s', uid = %d, name = '%s' WHERE cid = %d", $edit['status'], $edit['timestamp'], $edit['subject'], $edit['comment'], $edit['format'], $edit['uid'], $edit['name'], $edit['cid']); db_query("UPDATE {comments} SET status = '%s', timestamp = %d, subject = '%s', comment = '%s', format = '%s', uid = %d, name = '%s' WHERE cid = %d", $edit['status'], $edit['timestamp'], $edit['subject'], $edit['comment'], $edit['format'], $edit['uid'], $edit['name'], $edit['cid']);
_comment_update_node_statistics($edit['nid']); _comment_update_node_statistics($edit['nid']);
...@@ -991,7 +991,7 @@ function comment_save_settings() { ...@@ -991,7 +991,7 @@ function comment_save_settings() {
$_SESSION['comment_comments_per_page'] = $comments_per_page; $_SESSION['comment_comments_per_page'] = $comments_per_page;
} }
drupal_goto('node/'. $edit['nid'] .'#comment'); drupal_goto('node/'. $edit['nid'], NULL, 'comment');
} }
function comment_num_all($nid) { function comment_num_all($nid) {
......
...@@ -348,7 +348,7 @@ function comment_reply($nid, $pid = NULL) { ...@@ -348,7 +348,7 @@ function comment_reply($nid, $pid = NULL) {
return comment_preview($edit); return comment_preview($edit);
} }
else { else {
drupal_goto("node/$nid#comment-$cid"); drupal_goto("node/$nid", NULL, "comment-$cid");
} }
} }
else if ($_POST['op'] == t('Preview comment')) { else if ($_POST['op'] == t('Preview comment')) {
...@@ -548,7 +548,7 @@ function comment_save($edit) { ...@@ -548,7 +548,7 @@ function comment_save($edit) {
if ($edit['cid']) { if ($edit['cid']) {
// Update the comment in the database. // Update the comment in the database.
db_query("UPDATE {comments} SET status = '%s', timestamp = '%d', subject = '%s', comment = '%s', format = '%s', uid = %d, name = '%s' WHERE cid = %d", $edit['status'], $edit['timestamp'], $edit['subject'], $edit['comment'], $edit['format'], $edit['uid'], $edit['name'], $edit['cid']); db_query("UPDATE {comments} SET status = '%s', timestamp = %d, subject = '%s', comment = '%s', format = '%s', uid = %d, name = '%s' WHERE cid = %d", $edit['status'], $edit['timestamp'], $edit['subject'], $edit['comment'], $edit['format'], $edit['uid'], $edit['name'], $edit['cid']);
_comment_update_node_statistics($edit['nid']); _comment_update_node_statistics($edit['nid']);
...@@ -991,7 +991,7 @@ function comment_save_settings() { ...@@ -991,7 +991,7 @@ function comment_save_settings() {
$_SESSION['comment_comments_per_page'] = $comments_per_page; $_SESSION['comment_comments_per_page'] = $comments_per_page;
} }
drupal_goto('node/'. $edit['nid'] .'#comment'); drupal_goto('node/'. $edit['nid'], NULL, 'comment');
} }
function comment_num_all($nid) { function comment_num_all($nid) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment