Jump to content

Bbpress Ignore User: Fatal Error While Activation The Plugin


strayAncient

Recommended Posts

Hello World! My first post here.

 

I have a weird problem with "bbPress User Ignore" plugin for WordPress. I am using wampserver (clean install) for coding a quick mod needed for a website. Installed the latest version of WP, bbPress and bbPress Ignore User.

 

In WP Dashboard, could not activate the plugin. Throws a fatal error. The exact error shown:

 

Plugin could not be activated because it triggered a fatal error.

 

Parse error: syntax error, unexpected 'endforeach' (T_ENDFOREACH) in C:\wamp\www\wordpress\wp-content\plugins\bbpress-ignore-user\bbpress-ignore-user.php on line 169

Have I missed turning on/off or editing a simple required option in one of the configuration files?

 

Apache Version: 2.4.2

PHP Version: 5.4.3

MySQL Version: 5.5.24

There's likely a syntax error on the line(s) right above that point (the WP style of programming makes it easy to break the syntax, but hard to find the problem.) Post lines 159-169 of that file.

159-169 coming up...

 

<tr>
<td class="label">Ignored Users List</td>
<td class="data"><?
foreach ($ignored_users as $user_id => $user_login) :
$ajax = "jQuery.post(IgnoreUser.ajaxurl,{'action':'bbp_5o1_unignore_user','data':'delete ".$user_id.";user_id ".$displayed_user_id."'},function(response){if (response){user=document.getElementById('ignored-user-".$user_id."');user.parentNode.removeChild(user);}});";
?>
 <span id="ignored-user-<?php print $user_id; ?>" style="display: inline-block; line-height: 1.5em; margin: 3px; padding: 2px 5px; background: #eee;">
 <span style="padding: 0 5px 0 0;"><?php print $user_login; ?></span>
 <a style="cursor: pointer;" title="Remove" onclick="<?php print $ajax; ?>;">✖</a>
 </span>
<?php endforeach; ?></td>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.