• I’m having trouble with Permalinks – only Setting>Permalinks>Custom Structure allows Posts, Categories and Tags to work (without going to 404 Error page) – but now I can’t navigate pages around the site; for example, on Home Page of my site – http://golovegreece.com/ – if I try, in bottom left corner of blog, to go to page 2, an Error 404 page will appear.

    I’m working on the theory that it’s an .htaccess file problem. Using FTP, I’ve located the .htaccess file in html root folder – see screenshot here: http://i1171.photobucket.com/albums/r556/pushkin64/htaccess.jpg.

    The file says:

    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

    Is the .htaccess file in the right place? Should it be somewhere else? Are its contents correct? Any other ideas what might be causing my Permalinks problem?

    Many Thanks

Viewing 14 replies - 1 through 14 (of 14 total)
  • Your htaccess file is correct and it is in the right place. It should be in the same directory, root or otherwise, as wp.

    Thread Starter pushkin

    (@pushkin)

    Thanks for reply.

    So, if everything with .htaccess file is allright, then any other ideas as to what’s causing my Permalinks problems?

    Thanks

    http://validator.w3.org/checklink?uri=http%3A%2F%2Fgolovegreece.com%2F&summary=on&hide_type=all&depth=&check=Check shows all the permalinks being redirected which would be wrong.

    Have you tried:
    – deactivating all plugins (yes, all) to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s). Don’t forget the ones in mu-plugins if you have one that folder. If you can’t get into your admin dashboard, try resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems.
    – switching to the Twenty Eleven theme to rule out any theme-specific problems.

    Thread Starter pushkin

    (@pushkin)

    Not only did I deactivate all plugins, but I deleted every plugin from Dashboard and from the FTP plugins folder – and still no joy. Switching to 2011 theme didn’t do the trick either – same old 404 page.

    I also checked out the site on local host and here it works as it should. If I use the Search Site feature in top right hand corner of blog and type in Athens, it comes up with the following URL for page 1

    http://localhost/?s=athens

    and I can then navigate, using numerical buttons 1, 2, 3, to pages 2 and 3, which appear as:

    http://localhost/page/2/?s=athens
    http://localhost/page/3/?s=athens

    If I try and do the same on external host, the first page will appear as:

    http://golovegreece.com/?s=athens (this works); but if I then try to navigate to page 2, it appears as :

    http://golovegreece.com/page/2/?s=athens

    and goes to error 404 page.

    What I have noticed is that if I remove the / separating ‘page’ and ‘2’, so the URL becomes http://golovegreece.com/page2/?s=athens, then this works.

    But if I then try and navigate from page 2 to page 3, the following URL appears:

    http://golovegreece.com/page2/page/3/?s=athens

    and goes to an Error page.

    What can I do? All help greatly appreciated. Thanks

    What settings do you have in the permalinks?

    Thread Starter pushkin

    (@pushkin)

    I think I’ve managed to narrow my problem down a bit, and have started a new thread covering it. The problem is, I think, Paged Navigation Not Working, and here’s the new thread. (Apologies for all the threads).

    http://wordpress.org/support/topic/paged-navigation-not-working?replies=3#post-2805901

    I’ve mentioned on that thread the following regarding settings:

    Custom permalinks – which I’ve got set at archives/%postname%/ – works with posts, categories and tags, but not when navigating pages.

    Only on default does everything work. Day and Name, Month and Name, Numeric, and Post Name work with posts or categories or tags, but not all of them and none of them allows me to navigate pages.

    Thread Starter pushkin

    (@pushkin)

    This is the screenshot of what my Permalinks settings look like:

    http://i1171.photobucket.com/albums/r556/pushkin64/permsettings.jpg

    There is a problem with what the screen shot shows.
    It should be /%archives%/%postname%/

    I am not sure archives is a structure tag though.

    Thread Starter pushkin

    (@pushkin)

    I came up with /archives/%postname%/ – it’s a combination of Numeric and Post Name – because it was the only non-Default setting that allows Posts, Tags and Categories to work, i.e. it avoids going to 404 error page. Problem with /archives/%postname%/ is that page navigation has error page issue.

    Your suggested structure – /%archives%/%postname%/ – takes categories, tags, page navigation to error 404.

    if you want to have monthly archives via permalinks, you need to use a full structure with year, month, and day (which is recommended) like: /%year%/%monthnum%/%day%/%postname%/

    http://wordpress.org/support/topic/problems-with-archives-and-categories-links?replies=14

    Thread Starter pushkin

    (@pushkin)

    It doesn’t matter what custom structure I come up with, either categories, tags or navigation will lead to Error page. Depending on which custom structure I use, I can get categories, tags and navigation to work, but not all at the same time; for example, in structure archives/%postname%/, posts, categories and tags are fine, but navigating pages goes to error 404. Only on Settings>Permalinks>Default – with the ‘ugly’ permalinks – does everything work correctly.

    I’ve been through all suggestions so far – I’ve even gone through all my posts to make sure all links that are internal to site are now showing default permalinks and not any sort of customised structure – and still I’m getting 404 error page. Any other suggestions would be appreciated.
    Thanks

    Thread Starter pushkin

    (@pushkin)

    I’ve come to the conclusion that this has got nothing to do with the .htaccess file. This is a problem to do with custom permalinks causing pagination not to work.

    When pagination works, i.e. when permalinks are set to Default, pages look like this: http://golovegreece.com/?paged=2.

    When pagination doesn’t work, i.e. when permalinks are customised, then pages look like this: http://golovegreece.com/page/2/

    Any ideas how to solve this problem? Thanks

    Check with your hosts that mod_rewrite is running on your server.

    Thread Starter pushkin

    (@pushkin)

    According to my hosts – GoDaddy – everything is in working order their end, including mod rewrite. I’ve a feeling this htaccess is a red herring. I think my issue is more to do with this (http://wordpress.stackexchange.com/questions/6343/wordpress-pagination-with-custom-post-type) and the solution is to modify the query code, whatever that is.

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘Is .htaccess file in right place?’ is closed to new replies.