Arrow

Implode Error | Peter's Login Redirect | Forum

Back to the login redirect plugin page
 
Current User: Guest
Search Forums:


 






Minimum search word length is 4 characters – Maximum search word length is 84 characters
Wildcard Usage:
*  matches any number of characters    %  matches exactly one character

Implode Error

Reply to Post Add a New Topic
UserPost

11:03 am
May 10, 2010


SarahB

Guest

Hi Peter! First of all, thanks for making such a great plug-in, I have used it on a number of my sites already!

I am currently receiving the following error while trying to access the "Login Redirects" menu in the administrative area of my site.

PHP Warning: implode() [<a href='function.implode'>function.implode</a>]: Invalid arguments passed in wp-contentpluginspeters-login-redirectwplogin_redirect.php on line 210

Line 210:

$exclude_users = "'" . implode($exclude, "','") . "'";

I have disabled all of the other plug-ins I have installed and I am still receiving the error.

I'm running WP Version 2.9.2.

Any suggestions on what I will need to do to get this running? Thanks in advance, I really appreciate your help!

~SarahB~

7:34 am
May 13, 2010


Peter

Admin

posts 732

Try switching the order of the parameters passed to "implode":

$exclude_users = "'" . implode("','", $exclude) . "'";

8:17 am
May 13, 2010


SarahB

Guest

Peter said:

Try switching the order of the parameters passed to "implode":

$exclude_users = "'" . implode("','", $exclude) . "'";

Thanks for the response Peter, but unfortunately updating the parameters did not help. I am still receiving the same error that I have listed above. Any other ideas on what I can do to troubleshoot this error?

Thanks!

8:15 pm
May 13, 2010


Peter

Admin

posts 732

I'm not sure, as there shouldn't be an inherent problem in the plugin around that, and even the implode function should accept those parameters in either order. Also, I cannot reproduce the problem.

Try doing a var_dump( $exclude ); before that line to see what is contained in the $exclude variable. It should be an array (whether empty or not).

9:22 pm
August 12, 2010


Baf

Guest

Have the same error. Wordpress 3.0 Russian. What can I do to use your plugin?

12:44 pm
August 14, 2010


Peter

Admin

posts 732

Unfortunately, this mystery was never solved. Did you inspect the contents of that $exclude variable as noted above? Have you checked to see whether the login_redirects table was successfully created upon activating the plugin (if it wasn't, you might have to manually create it using the SQL in the plugin file)? Are you using a multi-site install or something other than a plain one-site install?

3:08 am
August 19, 2010


Baf

Guest

Hi!
In php im full noob, so I just comment this line of code

$exclude_users = "'" . implode($exclude, "','") . "'";

with

//

at the start and it worked!
Will it broke something in the future? =)

3:51 pm
August 20, 2010


Peter

Admin

posts 732

In that particular case, it's mostly harmless, but I'm going to release an update to the plugin that should bypass the problem.

Reply to Post

Reply to Topic:
Implode Error

Guest Name (Required):

Guest Email (Required):

HTML Editor
Smileys
Confused Cool Cry Embarassed Frown Kiss Laugh Smile Surprised Wink Yell
Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
6 + 9