Hi TammyM
Normally there will not be an .htaccess file in your /uploads/ sub directory. If you want to place an .htaccess file then include the code below into your /uploads/ .htaccess file
Options -Indexes
DirectoryIndex index.php index.html
#block hackers from these type of files #
# multiple file types
<FilesMatch ".(htaccess|php)$">
Order Allow,Deny
Deny from all
</FilesMatch>
This will block execution of php scripts located in the /uploads/ sub directory. It will make it useless for hackers to try to upload php hacking code into your uploads sub-directory.
It looks like you are following http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory and I too tried it out on my experimental WP blog and got the same results as you did … line 17 …
I did not have any such problems in previous versions of WP so not sure if this is related to 3.9.1 or earlier. Anyway there are many fixes required in WP 3.9.1 and I hope they are done soon.
Back to your problem:-
The index.php file in http://www.durhamcommunityfoundation.ca
should be:
require( dirname( __FILE__ ) . '/dc/wp-blog-header.php' );
And this should work for you as your core WP files are in /dc/ sub-directory.
I hope this works.
TammyM, I just checked your site http://www.durhamcommunityfoundation.ca
When I visit I see a maintenance page with a link to the admin login: http://www.durhamcommunityfoundation.ca/dc/wp-login.php
So far you seem to have configured it right. Can you login?
Thread Starter
TammyM
(@tammym)
Thanks guys. I was able to get the site running by NOT putting an .htaccess file in the root directory. Silly I know.
Peter, I have not has this issue prior to this version of WP either. This was a fresh install of WordPress 3.9.1 so I figured that it was an error in the programming when I found the .htaccess in the uploads sub-directory. I will add that code just in case.
Every time I did put a copy of the .htaccess into the root, it would cause everything I clicked on in the dashboard to attempt to open a php file rather than to execute an action.
I’m not happy with how it is working at the moment BUT it is working.
My concern now is that when WP updates again that things will run amok with the current set-up and create a whole new set up headaches for this client.
Just wondering what is in your root .htaccess file.
Mine is
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /test/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /test/index.php [L]
</IfModule>
# END WordPress
but I noticed that your index.php file had
require( dirname( __FILE__ ) . '/wordpress/wp-blog-header.php' );
in your case the subdirectory should not be /wordpress/ but /dc/ as in
require( dirname( __FILE__ ) . '/dc/wp-blog-header.php' );
From your comments I was not sure if you had changed it from ‘wordpress’ to ‘dc’. I think it should work as it can now find the correct directory in your website.