This hit us today, too – anyone who reads this: Please wait with plugin update until the author has fixed this bug.
If you already have been hit, you can fix it yourself, edit listing_flagging.php like so:
business-directory-plugin/includes/helpers/listing_flagging.php
76c76
< if ( empty( $data[ ‘reason’ ] || empty( $data[ ‘comments’ ] ) ) ) {
—
> if ( empty( $data[ ‘reason’ ]) || empty( $data[ ‘comments’ ] ) ) {
Kind regards
Markus
Thank you! Thank you! Thank you!! This fixed the bug perfectly. For anyone else who might read this post, the latest version of Business Directory plug in requires PHP 5.6. My server is running 5.4 by default so I had to get my hosting provider to upgrade to 5.6. Luckily, it did not create compatibility issues with any other plug ins I have installed, but I thought I would mention it so people aren’t shocked if it happens to them.
Thanks again!!
Same problem here, but unfortunately for me, Markus’ solution did not work.
If anyone has another idea, I am humbly grateful.
Thanks!
Marsha
That is unfortunate.
I literally replaced the code on line 76 with:
if ( empty( $data[ ‘reason’ ]) || empty( $data[ ‘comments’ ] ) ) {
and all my problems went away…except that this plug in now requires PHP 5.6 and I had to upgrade my server.
Yea! Once I upgraded to PHP 5.6 I was in business.
Many many thanks!!!!!
Hi everyone,
Sorry that you ran into issues with this!
First, BD requires that you be running PHP 5.6 since 5.0. At this point, it’s also the minimum recommended version for WordPress itself, so you should always make sure you’re at the minimum version. A lot of web hosting companies we’re finding are NOT upgrading folks automatically which is causing problems…
Second, for the Flag Listing issue, I’ll get the developers on that right away…that’s definitely not correct behavior. My apologies for missing that during testing.
We’ll get a patch out for that ASAP.
UPDATE: This problem appears to affect only versions that are OLDER than PHP 5.6. This explains why it wasn’t caught prior to release–we no longer test or validate on versions pre-5.6.
We will issue the patch on 1/26/2018 but we still strongly recommend that everyone upgrade to PHP 5.6 or higher on their hosting, per WordPress.