Hi Jacques,
It is disabling users as expected, works fine..but normal users get this message when they change things in their accounts or for new users (major conflict I guess):
Warning: Missing argument 2 for ja_disable_users::user_login() in /home/soloscom/public_html/wp-content/plugins/disable-users/init.php on line 116
Very strange..any ideas what is going on???
I opened a thread on the plugin author’s support page too; if you want to follow it or comment there??
Thanks
Sanjay
Hi Jacques,
The Disable User plugin author never responded; I found out a way to display custom messages to people by userid, with that I am okay, don’t need to disable them per say. So please don’t worry about this, I have disabled the “disable this” plugin from my site (no pun intended).
Sanjay
For people who want to know how to display user specific messages in header (or anywhere else) here is the code (tested and works well). The userids who I want to show the message to are stored in an array. If the current user id is found in that array, the specific message is displayed.
<?php if(is_user_logged_in())
{
$a = array(2, 2939, userid);
global $user_ID;
if (in_array($user_ID, $a, true))
{
echo "Message to these users";
}
}
?>
I liked this option instead of disabling the user-because you can just put a huge block of message right at the header (and the messsage can be annoying in colors, etc) to make sure they get that that their trial period is over; instead of blanketly removing their access to the site.
-Sanjay
Just to be clear…the variable $a is the array of userids you want to display a specific message to:
$a = array(2, 2939, 5555, 6666);
is the actual array of the userids..I typed “userid” in the previous post, but to be clear, the $a is the array with all userids, all integers.
Sanjay