Fresh WordPress install does not open site…
-
Just Installed wordpress, and also reinstalled it, but it will not open my site…
I somehow managed to get to the dashboard, and if I post a comment and click on the preview button it looks correct, but if I click on visit site all I get is a list of the files in the wordpress directory. I cannot do anything from there but randomly click stuff hoping something works, but it never does.
I found an uninstall plugin, and installed it and tried to run it from the tools menu like it says to do in the readme file but it just keeps saying “are you sure you want to uninstall wordpress” and I say ok and it goes right back to ” are you sure you want to uninstall…”
-
A link to the site please?
This is not a public site. I just set it up to learn about WP, and plugins, etc…
I can’t understand WordPress, I have completely uninstalled it and reinstalled it like 4 times trying different locations and even putting the files directly into public folder of the webserver…
Google searches, youtube, hours of reading articles just to find out that they don’t address my actual issue…
No matter what I try I cannot get to anything but a listing of the files in the public folder.
If I manually type localhost/site_name I get the site but it says “oops cannot find that page” or something like that. Then I click on dashboard and get the index of the folder again!
I suspect that I’m not the first to have this problem as I followed the 5 minute install instructions each time I attempted to set this thing up.
I removed the DB, and user, and deleted all of the wp files, then recreated the db and user each time I tried installing it. It always says it installed correctly and brought me to the login page, when I logged in it brought me to the dreaded index again instead of the actual site.
I am at my wits end here. Spent several days trying to resolve this issue but cannot find any concise help that addresses this particular problem…
I am trying to learn about WordPress but cannot get past the install – totally lame, I know…
Any ideas, or help would be very much appreciated.I can’t understand WordPress,…
…I am trying to learn about WordPress but cannot get past the installI would dare say you are suffering from some server configuration issues, rather than WordPress issues. How are you hosting WordPress?
1) What OS: Windows, Linux, OSX – and what version or distribution?
2) How did you install the server environment – WAMP, XAMPP, Bitnami, MAMP, or individual components, or something different?
3) If you’ve installed on a Linux distribution, how did you install WordPress – through a package manager, or by setting up the WordPress package directly in /var/www/* ?
if I post a comment and click on the preview button it looks correct, but if I click on visit site all I get is a list of the files in the wordpress directory
Is there an “index.php” file in that list, and if the answer is yes, what happens when you click on it?
-
This reply was modified 8 years, 5 months ago by
Clayton James.
-
This reply was modified 8 years, 5 months ago by
Clayton James.
Hi,
OSX 10.11.6
Apache 2.4.18
PHP 7.0.11
MariaDB 10.1.17I enabled Apache on the MAC, and used Homebrew to install PHP and MariaDB
I also installed PHPMyadmin 4.6.4, manually.
Everything seems to be working… I have some PHP stuff in there that works correctly,
And the wordpress install looks like it works right. I just can’t figure it out… If it is a server issue I don’t know what. I have not found anything in my searches about that. Would like to get it working though. Thanks.Yes there is an index.php in there, if I click on it I get the listing of files in the wordpress folder…
I notice that in the listing of the public folder ( localhost-index of/ ) the actual index has been taken over by wordpress…
ie, the listing now has the wordpress watermark on the page whereas before it was just the list of folders and files, similar to doing an ls in unix…I’m not quite sure I follow this:
Yes there is an index.php in there, if I click on it I get the listing of files in the wordpress folder…
…the listing now has the wordpress watermark on the page whereas before it was just the list of folders and files,So, is it displaying a list of files and folders, or is it displaying a WordPress install script? WordPress doesn’t water mark anything in an Apache directory listing.
If an index.php file is present in the web root, then your browser should automatically attempt to render it. If you installed WordPress in its own directory, when you navigate to
https://localhost/wordpress/
for example. You should see an installation script like the example I linked to above. If you’ve mixed the WordPress files with other preexisting files located in the root directory, then that needs to be rectified. Files from two sites or other web projects can’t be served from the same directory.If you can navigate to any web-accessible directory in your browser, and it displays a list of files that includes an ‘index.php’ file, then Apache probably isn’t configured to serve
index.php
files. Apache should be automatically rendering that index.php file, not ignoring it and showing a directory listing instead.https://www.dropbox.com/sh/gx8blow0vti2bz1/AAC_op7MO7s3AWJi9kiWymPra?dl=0
Some screen shots of what I’m trying to describe…
As you can see, if I enter the URL to the site manually (localhost/wordpress/artssite)
I can successfully open the page, but there is that “opps” message there…
then once I click either dashboard, or the site admin link I am returned to the index of the wordpress folder.
Likewise, if I manually enter ‘localhost/wordpress/wp-admin/index’ I will get to the dashboard but when I click on ‘visit site’ I get the index of the wordpress folder.PHP is obviously capable of rendering php, and there’s no problem with index.php files as shown in your //wordpress/wp-admin/index.php example.
if I manually enter ‘localhost/wordpress/wp-admin/index’ I will get to the dashboard but when I click on ‘visit site’ I get the index of the wordpress folder.
My best guess is that you may need to configure the Apache “DirectoryIndex” directive so that Apache knows that it is supposed to serve
index.php
files by default. I’m guessing that’s probably why you get a directory listing instead of opening the index.php file automatically.“how to” DirectoryIndex order Apache
“how to” apache “index.php instead of index.html” (Links go to Google)
Get that sorted first, then see if the 404 error persists. If so, we can address that to find out if it’s going to be a permalink/Apache mod_rewrite issue, or something different.
I’m not sure how this happened:
https://www.dropbox.com/sh/gx8blow0vti2bz1/AAC_op7MO7s3AWJi9kiWymPra?dl=0&preview=result_of_clicking_view-site+in+dashboard.png
That’s a screenshot of a combination of the directory listing for /wordpress and a partial rendering of the “readme.html” file that resides in that directory, in the same viewport. I have no clue why that would happen.
-
This reply was modified 8 years, 5 months ago by
Clayton James.
-
This reply was modified 8 years, 5 months ago by
Clayton James.
-
This reply was modified 8 years, 5 months ago by
Clayton James. Reason: havin' trouble with my back-ticks, lol
-
This reply was modified 8 years, 5 months ago by
Clayton James.
ok I’ll change the indexes options for the directory and see if that helps…
Kinda sounds like that may be why this is happening. I remember setting that option when I configured the apache server to use a different document root.
I’ll post the results.
ThanksWell,
I did change the Indexes options for the DocumentRoot and added index.php and index.html to the DirectoryIndex. Stopped and started the server, even rebooted, but now I just get Forbidden-You don’t have permission to access /wordpress/wp-admin/ on this server.
I checked the perms, and I am the owner…I still can enter the paths to the site, and to the dashboard but the same behaviour exists (with the exception of getting the Forbidden message as opposed to the directory listing) when I try using the links on the respective pages to switch back and forth between the homepage, and the dashboard…
At one time I used MAMP to install all of this, but had some SQL probs so I reinstalled everything without using MAMP hoping that might solve the SQL issue. It didn’t. However, WordPress worked find under MAMP. And SQL is not the problem in this case.
I wonder what the difference is. All of the other existing code runs fine, It’s just WP.
Frustrating!I think what you may have done is disabled casual directory browsing by changing Index Options, rather than telling Apache to serve index.php files using the DirectoryIndex settings, so now Apache returns a forbidden error because it doesn’t recognize the index.php file. Apache still hasn’t been given instructions to serve the index.php file.
Try this.. Open finder and navigate to the wordpress directory. Turn on the show hidden files feature. Locate the .htaccess file – if there isn’t one, create one with Text Edit and save it to the directory. Place this at the very top of the .htaccess file and save the changes:
DirectoryIndex index.php index.html index.htm
See if that changes the symptom at all.
[edit] I should have elaborated a bit more:
I did change the Indexes options for the DocumentRoot and added index.php and index.html to the DirectoryIndex.
I’m wondering if the order could be affecting something, or if the syntax may be causing an issue for some reason. It certainly looks like you’re on the right track though. Try the .htaccess method and see if anything changes.
-
This reply was modified 8 years, 5 months ago by
Clayton James.
Here’s what I get after editing the .htaccess file…
I’m not sure of the syntax for the file, but here’s what I did.
I think at least it had some effect, although not what I hoped for…# BEGIN WordPress
<IfModule mod_rewrite.c>
DirectoryIndex index.php index.html index.htm
RewriteEngine On
RewriteBase /wordpress/
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /wordpress/index.php [L]
</IfModule># END WordPress
Here’s the server response after the .htaccess edit:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator at [email protected] to inform them of the time this error occurred, and the actions you performed just before this error.
More information about this error may be available in the server error log.
Looking at your screen shots I’m guessing that you aren’t using any virtual host configurations, but rather working on several projects located in sub-directories in the web root . That makes me think that it’s possible that the “AllowOverride” directive – the instructions that allow whether or not rules can be used in .htaccess files – is probably still in its default configuration of “AllowOverride None”. That will need to be changed before apache will obey any rules it finds in an .htaccess file – which will come in handy if you ever plan on changing the permalink structure in WordPress.
You can change that setting globally in httpd.conf by locating the following:
# AllowOverride controls what directives may be placed in .htaccess files. # It can be "All", "None", or any combination of the keywords: # AllowOverride FileInfo AuthConfig Limit # AllowOverride None
Change AllowOverride None – to – AllowOverride All, save the changes and restart apache.
There are a couple of references to AllowOverride in the file. Make sure you only change the one located under the commented text I mentioned above.
That may also explain your 404 “not found” error, if you’ve already changed the permalink structure from the dashboard.
Also, you need to place that DirectoryIndex line outside of the WordPress generated code. Try it at the very top of the file, before the WordPress code.
DirectoryIndex index.php index.html index.htm # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase /wordpress/ RewriteRule ^index\.php$ – [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /wordpress/index.php [L] </IfModule>
You’re right about the virtual hosts.
The AllowOverride directive is already set to ALL.
I have moved the DirectoryIndex line to outside the WordPress code so that it appears exactly as you have shown…
Rebooted, tried navigating to my site but got the :“Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator at [email protected] to inform them of the time this error occurred, and the actions you performed just before this error.
More information about this error may be available in the server error log”
message again…
Considering just scrapping the whole dev environment and starting again from scratch…
Don’t know if it will make a difference, but something isn’t right.
There must be millions of systems setup just like this, so it must work.
Just weird that this has not happened to at least some of them.
As far as my research has shown I’m the odd man out…
I appreciate your determination on resolving this issue, You’ve been great. Thanks.
I really don’t want to go through setting all of this up again, but what else is there to do? -
This reply was modified 8 years, 5 months ago by
- The topic ‘Fresh WordPress install does not open site…’ is closed to new replies.