Just installed ajax_comment and comment bonus api and when try to submit an comment I get the errror:
An Error occurred.
/ajax_comments/js
(no information available).

CommentFileSizeAuthor
#8 ajax_comments_basepath.patch638 bytesjcmarco
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mr.alinaki’s picture

You should install -dev version.

dishui’s picture

I have tried the dev version and get the exact same error.

dishui’s picture

anybody has some comments on this?

dishui’s picture

using xmlhttp tracing, I find why this problem occur:

the comment is actually submitted, if I refresh the page, the new comment showes up. However, firebug console showes a problem with jquery.js line 2806:

// Send the data
try {
xhr.send(s.data);
} catch(e) {
jQuery.handleError(s, xhr, null, e);
}

here is the trace:

The response headers shows that:

Content-Length 0

the Request Headers shows that:
Content-Length 183

Aniara.io’s picture

Was this fixed in recent versions? I'm also getting the same problem as #4.

bflora’s picture

getting same problem with both 6.1.8 and dev-6.1.x

oboz’s picture

I change path "ajax_comments/js" in all files to "ajax_comments/jsa"

But I have no idea what the problem.

jcmarco’s picture

Version: 6.x-1.8 » 6.x-1.x-dev
Status: Active » Needs review
FileSize
638 bytes

The problem is because there is no basePath in line 410,
This error only happens if Drupal is not installed in the web server root

zarudnyi’s picture

Unfortunately patch don't work for me.

neochief’s picture

Status: Needs review » Fixed

jcmarco, thanks, your patch makes sense! Commites to dev. Does this patch fix issues for anybody else in thread?

kruser’s picture

I am getting this error with the March 14 dev release.

But now I'm also getting an error notice.

warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, 'ajax_comments_js' was given in /includes/menu.inc on line 348.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

core44’s picture

Status: Closed (fixed) » Active

I have tried both the latest dev release and stable release and I have this error when edit comments on both version.

An error occurred. <br />/ajax_comments/js<br />(no information available).

Anyone else still receiving this error? And any suggestions for a fix?

dinkydule’s picture

I'm using the stable release (ajax_comment 6.x-1.8 and comment bonus api 6.x-1.x-dev) and I'm getting this error when I submit a comment. After refreshing the page, I can see that the comments have in fact been submitted.

dinkydule’s picture

I solved my problem by changing the settings so that replying to a comment takes you to another page. I'm no longer getting an error message when I submit a comment, or reply to a comment.

toemaz’s picture

If you have the devel module spitting out some extra data at the end of the requests, use

$GLOBALS['devel_shutdown'] = FALSE;

If not, you may get the error as submitted in the title.

alomari-1’s picture

any update?? i am getting this problem after upgrading my drupal 6.19 to pressflow 6.22
any idea about the reason??

manjeet’s picture

i was facing the same issue, the reason for the same was - i changed the text of the Comment submit form from 'Save' to 'Post Comment'.
It was failed to enter any of these 2 conditions:

if ($form_state['values']['op'] == t('Preview')) {
$output = '

'. $form['comment_preview']['#value'] .'

';
if ($output && $form_state['values']['pid']) {
$output = '

'. $output .'
';
}
}
elseif ($form_state['values']['op'] == t('Save')) {
$output = '
'. $form_state['storage']['ajax_comment'] .'

';
}

I renamed by button back to save and it worked. :-)

terbs’s picture

I had this same error. My issue was also the same as #18, the error was caused by a separate module doing a form alter on the submit button.

calefilm’s picture

Thanks Manjeet! That was my problem also.

webpavilion’s picture

I had this bug. Because of here this lines in nginx:

        location ~* ^.+(css|js)$ {
                expires max;
                gzip_static on;
        }

need to add \. like this:

        location ~* ^.+\.(css|js)$ {
                expires max;
                gzip_static on;
        }

and everything works well.

Als’s picture

Issue summary: View changes

Still having this problem with the latest 6.x versions.
I confirm that Manjeet's solution at #18 works also with translations: I had renamed the post button "Invia" (Italian for "send"), switched it back to "Salva" ("save") and the error went away.

qzmenko’s picture

Status: Active » Closed (outdated)

Issue is closed because 6.x version is unsupported. Feel free to open new issue for 7.x or 8.x versions of module.