This seems to be something that crops up from time to time and relates to the AJAX Error issue encountered by @sico7 and @mrjkconnor on this support question. I should have updated the thread with the results of what I discovered on the system that @sico7 is running under, but just as I was about to hit reply, the topic was closed by the remarkably vigilant moderator!
Anyway, it appears that on some hosts (academic ones, for example) where WordPress is not given sufficient privileges to modify the database structure, CommentPress is not able to add a ‘comment_signature’ column to the comments table of the site it is being activated on. Therefore comments left on paragraphs are never associated with them. One of the symptoms of this is that the AJAX error they report is triggered.
If this describe the symptoms you’re seeing and you’re using CommentPress on an academic system, it’s likely you will need to talk to your server admin(s) to see what can be done. If there is indeed no ‘comment_signature’ column, they will have to add one manually. The following should be enough:
ALTER TABLE '$wpdb->comments' ADD 'comment_signature' VARCHAR(255) NULL;
$wpdb->commentsis the full name of the comments table on your site.
Thanks for this, sorry about posting it in the wrong place. I fortunately have admin for the virtual machine so I will do this and report back.
If I were to change the privileges for the SQL database user rather than add in the column, what would the user need?
You are a star, thank you for a swift, correct and to the point reply!
Glad it’s working for you now. I’ll leave this open for the time being in case others have anything new to contribute.
This has worked well for everyone other than one person using a Mac. Is there any reason why a Mac user might get the error :
“TypeError: Cannot read property ‘toString’ of undefined”
whilst commenting when commenting works fine for windows users (and android users actually).
Thanks for any further help you can offer.
@mrjkconnor, that is curious. Without seeing this in action, I can’t really offer any guidance, I’m afraid.
We’re running a multisite instance of WordPress. Will the ALTER need to be done every time a new CommentPress site is set up?
@yale_itg, no – only in cases where WordPress is not given sufficient privileges to modify the database structure.
- The topic ‘AJAX Error when commenting on academic servers’ is closed to new replies.