• Resolved mikejarrett

    (@mikejarrett)


    Background: We had a site built for us (but the developer is long gone), and we want to migrate it to a test area, update it, and then redirect our dns to point to the new version.

    Environment: We are running those on our own servers, and have complete root access.

    Our issue: We like this old site template and want to change mostly our content (for the most part, our site is “page-based” and not much posting). We downloaded the latest version of wordpress, setup the database and got it all working. We exported from our old version, and uploading into the new, and it all seems to work fine, except, the permalink are the default (e.g. https://www.sitename.com/?page_id=11). In our old site, it uses the url structure that we like (https://www.sitename.com/wp/client-case-studies) and has the permalink setting as /%postname%/.

    When we set the Permalink settings to the format that we like, nothing works. (that is, every page gives a 404).

    Our .htaccess file looks like this:
    # 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

    We are running this on a server that has never had wordpress installed, so there might be an httpd.conf issue.

    Any help would be greatly appreciated.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Check that mod_rewrite is running on your server.

    Thread Starter mikejarrett

    (@mikejarrett)

    Ah, yes, that was the problem. Thanks for the suggestion.

    Of course, since nothing can ever be easy, it took me a little time to figure out how to turn on mod_rewrite. What I had to do was edit the http configuration (for Centos, it is in /etc/httpd/conf/httpd.conf. )

    Under the <Directory “[my documentroot]”>
    The default is:

    AllowOverride None

    Change it to:

    AllowOverride All

    Then restart apache (service httpd restart)

    That got it working for me.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Permalinks revert to old style, and can't be modified’ is closed to new replies.