The effects of alcohol on sustanon 250 leucine for – real weight loss & bodybuilding benefits?
Share:
Notifications
Clear all

Limited Support

Our team is currently on holiday, so support will be limited during this period. Response times may be slower than usual, and some inquiries may be delayed.
We appreciate your patience and understanding, and we’ll resume our usual support by the end of August.

 

[Solved] allow empty comment

6 Posts
2 Users
0 Reactions
1,489 Views
Posts: 16
 itlr
Topic starter
(@itlr)
Eminent Member
Joined: 5 years ago

Hello,

How can I allow user submitting comment with empty text (rating required)? I tried this code snippet but it didn't work: 

add_filter( 'allow_empty_comment', function ($allow, $data) {
  return true;
}, 10 , 2 );
5 Replies
Asti
Posts: 8075
 Asti
Support
(@asti)
Illustrious Member
Joined: 8 years ago

@itlr,

We're really sorry, but wpDiscuz doesn't allow empty content. However, I've asked the developers to check this and if it's possible, they'll add the feature in the future versions of the wpDiscuz plugin. 

Posts: 16
 itlr
Topic starter
(@itlr)
Eminent Member
Joined: 5 years ago

@asti I see. As a work around, is there a way to set a default text? 

Posts: 16
 itlr
Topic starter
(@itlr)
Eminent Member
Joined: 5 years ago

@asti or allowing only spaces in comment text and setting a default space-only default comment? 

2 Replies
Asti
 Asti
Support
(@asti)
Joined: 8 years ago

Illustrious Member
Posts: 8075

Dear @itlr,

There is not an easy solution we can post here. This requires some custom coding. 

Asti
 Asti
Support
(@asti)
Joined: 8 years ago

Illustrious Member
Posts: 8075

Dear @itlr,

The new version already has this feature. Now you can use the "allow_empty_comment" hook. Besides adding the hook, you should also change the following options as well:

  • Comment Text Length
  • Reply Text Length

The values of those fields should be set to 0. 

Share: