garywed
Forum Replies Created
-
Hi All.
Thought I’d provide an update on how I solved this issue. I’ve been away for 6 months or so, using WP on BlueHost and learning it there. Now that I am more comfortable with WP, I still wanted it on my laptop, so I could use/play with it there. So I revisited this problem tonight.First, I removed all vestiges of WP 2.8 and installed WP 2.9.1. I still had the same problem- Apache served up indexes of the directories instead of the index.php file. So I looked further into the htaccess files mentioned by ericmann and bh_WP_fan. They were both spot on. Here’s what I did to fix the problem- specific instructions for anyone else having this issue.
Open up a text editor (NOT MS-Word, tho Notepad will work; personally, I use the open source Crimson Editor). On a new document, place the line:
DirectoryIndex index.phpThis needs to be saved as .htaccess in the wordpress directory; for me, that was:
C:\Program Files\Apache Software Foundation/Apache2.2/htdocs/wordpress
Windows does not especially like “dot files”, so you may have to save as “.htaccess” (with quotes). You cannot, for example, copy a file and rename it .htaccess- Windows will complain. Crimson Editor lets me save directly as .htaccess.
The DirectoryIndex directive operates when a user requests a directory (e.g., http://localhost/wordpress). It basically says, before serving a directory listing, serve instead the index.php file if it exists. This is very important since WP depends on this behavior to function properly.
.htaccess files allow you to tweek individual directories, so they need not follow the global directives set in httpd.conf
One more change needs to be made. You need to tell Apache to allow any .htaccess directives it finds to override those in the httpd.conf file. This is an easy change.
Open the httpd.conf file; mine was located at:
C:/Program Files/Apache Software Foundation/Apache2.2/conf/httpd.conf
Scroll down an find the section that contains the following (there will be extra lines, mostly commented out):
<Directory “C:\Program Files\Apache Software Foundation/Apache2.2/htdocs/”>
AllowOverride None
</Directory>Change “AllowOverride None” to “AllowOverride All” (don’t use the quotes). This will tell Apache to allow .htaccess overrides when it find them.
That’s it. WP works great now on my laptop. Thanks to bh_WP_fan and ericmann for their suggestions.
—GJWAnyone?
Hi All.
Here’s three links to screen shots of WP as I try to view a newly created post.Creating the new post.
Type the post. The small red arrow indicates the “Publish” button I clicked to advance to the next screen.Publishing the new post.
Post published. Again, the small red arrow indicates the link I clicked to advance to the next screen.Surprise! An index, not a post.
As you can see, clicking “View Post” returns an index of the /wordpress directory, not the postThanks!
—GJW