Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I have placed and previously used WordPress source on my web server everything is up and running including the DB. I even can access the site's admin page but in the theme settings page (Appearance/Themes) I'm getting these errors.

Warning: array_keys() [function.array-keys]: The first argument should be an array in /var/www/mysite/wp-includes/theme.php on line 513

Warning: uksort() [function.uksort]: The argument should be an array in /var/www/dialog/wp-admin/themes.php on line 73

Warning: array_slice() expects parameter 1 to be array, boolean given in /var/www/dialog/wp-admin/themes.php on line 94

Warning: array_keys() [function.array-keys]: The first argument should be an array in /var/www/dialog/wp-admin/themes.php on line 150

Warning: natcasesort() [function.natcasesort]: The argument should be an array in /var/www/dialog/wp-admin/themes.php on line 151

tried re-uploading the content but didn't work.I'm confused of what causing this error.

Thanks.

share|improve this question
2  
What WP version are you using? line 513 of wp-includes/theme.php is not PHP code in current version, it's comment –  Rarst Apr 8 '11 at 12:47

2 Answers 2

Try exporting your WordPress data, installing a fresh copy of the latest version of WordPress (currently 3.1.1), using a fresh database, and then re-importing your WordPress data.

share|improve this answer

This error is almost always a permissions error, usually caused by copying files from a Windows box to a Linux box via FTP. The issue is covered (and resolved) here, the long and short is this - "You might check your permissions on the wp-content, wp-content/themes and wp-content/plugins folder. If necessary make them 777."

Granted, there's something to be said for keeping WordPress on the latest version, but I'm of the opinion that WordPress updating should be done from inside WordPress - mainly to avoid issues like this. Once you've got it running, update to the latest version and it should have proper permissions. Additionally, this plugin will let you know what basic permissions need set for security.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.