Viewing 9 replies - 1 through 9 (of 9 total)
  • Is mod_rewrite running on your server?

    Thread Starter Famous

    (@famous)

    So the below is what the Apache httpd file looks like:

    [Code moderated as per the Forum Rules. The maximum number of lines of code that you can post in these forums is ten lines. Please use the pastebin]

    Thread Starter Famous

    (@famous)

    By the way I just realized my:
    http://localhost/blog/2012/06/16/hello-world/

    works!

    but:

    http://localhost/AAA/mySite/

    doesn’t work. It redirects to the localhost site as a 404 not found

    Have a look at .htaccess rewrite.
    What permalink structure are you using ?

    Thread Starter Famous

    (@famous)

    I meant to say this one doesn’t work:
    http://localhost/AAA/mySite/2012/06/post-title/

    this one does:
    http://localhost/AAA/mySite/

    The .htaccess is below, I took out three lines to fit the code guideline of 10 lines

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
    RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule  ^[_0-9a-zA-Z-]+/(wp-(content|admin|includes).*) $1 [L]
    RewriteRule  ^[_0-9a-zA-Z-]+/(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]

    Thread Starter Famous

    (@famous)

    My localhost site shows /blog/2012/06/16/hello-world/, but my directory site won’t.

    Here is the .htaccess file for the directory site:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress

    thanks for your help

    As per Esmi is rewrite on?
    Also what have you set in permalinks ?
    The code rewrite above just removes index.php from permalink.
    Any chance you have reversed date and title have you this in permalink.

    /%date%/%post%/
    or similar

    What is your url ??On pc 127 or local ?

    Thread Starter Famous

    (@famous)

    thanks for the follow through loughcorrib. I looked at this page:
    options-permalink.php

    and at the bottom of the page found this:
    If your .htaccess file were writable, we could do this automatically, but it isn’t so these are the mod_rewrite rules you should have in your .htaccess file. Click in the field and press CTRL + a to select all.

    Copied the code that it had in the box below it and pasted it to the .htaccess file and now it works great.

    Thanks

    Great ! glad you got sorted.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘cannot see posts’ is closed to new replies.