Forums

[resolved] I can never log in after I install WordPress (3 posts)

  1. lockwiz2
    Member
    Posted 4 years ago #

    I have tried off an on over the last year, about 10 times now to install WordPress, after each install I get the "Success!

    WordPress has been installed. Now you can log in with the username and password" but when I attempt to log in I always get an error message, always! This time the error is;
    Warning: Invalid argument supplied for foreach() in /virtual/lockman/public_html/wdpress/wordpress/wp-includes/capabilities.php on line 31

    I'm honestly not knocking this program, I think it's fantastic, I just would love to get it to work on my website like so many others have, I am hosted on ABhost.net server linux/unix system.

    Can anyone explain what the error warning means, here it is again, thanks for your help.

    "Warning: Invalid argument supplied for foreach() in /virtual/lockman/public_html/wdpress/wordpress/wp-includes/capabilities.php on line 31"

  2. moshu
    Member
    Posted 4 years ago #

    You may want to try the solutions offered on different related threads...
    http://wordpress.org/search/Invalid+argument+supplied+for+foreach%28%29+in?forums=1

  3. lockwiz2
    Member
    Posted 4 years ago #

    Thanks moshu...

    What finally worked for me was creating a ".htaccess file" using notepad and uploading that file to the root directory of WordPress, I found that solution on a web site somewhere yesterday (don't remember where) but here is how I created the .htaccess file:

    1. Open notepad and copy then paste the following two lines:

    php_flag magic_quotes_gpc off

    php_flag magic_quotes_runtime off

    2. Now save it with an extension of .htaccess but DON'T give it a "file name" just leave it as .htaccess

    3. Upload that .htaccess file into your WordPress root folder on your server.

    When I uploaded that .htaccess file to my WordPress root folder, WordPress began working immediately and allowed me to login...first time I have ever gotten WordPress to work after an install....it was all about the "Magic Quotes" being turned on at my server, they needed to be "off".
    (I still don't understand what the magic quotes thing is used for, but apparently it needs to be off for WordPress to function.
    This is finally my first time actually getting to use / try out WordPress...so far I have to say FANTASTIC!!! I love it! :)

    Hope this helps others with their installation.

Topic Closed

This topic has been closed to new replies.

About this Topic