WordPress.org

Ready to get started?Download WordPress

Forums

crippling permalinks bug! (20 posts)

  1. anatman
    Member
    Posted 5 years ago #

    Hi,
    After upgrading from 2.1 to 2.7, everything seemed fine, and i even decided to start using PHP5 to get Extended Live Archives working. The upgrade went well with no errors, and i could import all tags from UTW. The transition to a UTF8 database went well too.

    Today i noticed that even tough all is fine in the Admin section (the category and all post are there, i can edit them etc), i couldn't get the posts in one category in the blog to show up. The category archives show, but when clicking on the posts' links i will get to the homepage.

    Some poking around revealed this: for that one category, the posts will not show up, but the URL will be in the browser's address bar and links (like the read more link in the homepage) will think i am in the post's page.
    The category is called "ensinamentos", and i can get the posts to display if i try mydomain/e/postname. If i substitute the letter "e" in the address by anything i will get to the post. If i substitute the letter "e" by "en" i will get a 404 (correctly). If i then substitute the letter "e" by "ens" i will get to the homepage.

    For all other categories, if i try mydomain/anything-at-all/postname, i will get to the posts!!!

    My htaccess is standart except for some 301 redirects (for old page management). I can post it here if needed, as well as the blog address for testing.

    I will be gratefull for any help on this.

  2. anatman
    Member
    Posted 5 years ago #

    I just tried deactivating all plugins, and the problem is still here. I also tried going back to PHP4, but it didn't help (i did it through htaccess itself with AddHandler).

    All help will be much appreciated!

  3. mrmist
    Forum Janitor
    Posted 5 years ago #

    I'm not entirely clear what the issue is? The ensinamentos category doesn't show at all? It works for me on a stock 2.7 build. What permalink setup have you got?

  4. anatman
    Member
    Posted 5 years ago #

    Hi mrmist, thank you for your reply.

    If you go to my site (the homepage), you will see two posts: the one on the left is called "Penjin" and is in the "Ensinamentos" category. If you click on it, you will see that the URL in the browser changes to the post's URL, but you still see the homepage. The one on the right is in another category and can be accessed normaly.

    If you go to the "Ensinamentos" archive, it shows allright, but clicking on any silgle post belonging to that category takes you to the homepage.

    As a troubleshooting measure one can try to go to:
    1) http://taijiquan.pro.br/e/pengjin : this shows the post, surprisingly.
    2) http://taijiquan.pro.br/en/pengjin : this shows a 404 correctly.
    3) http://taijiquan.pro.br/ens/pengjin/ : this takes you to the homepage.
    4) http://taijiquan.pro.br/anygarbageatall/pengjin/ : shows the post, also very suprising.

    For all other categories, behavior is normal, except that simptom n. 4 is there too.

    The permalinks structure is: /%category%/%postname%/ which was working before the upgrade to 2.7. I have two other blogs in the same host, same setup, they work allright.

  5. anatman
    Member
    Posted 5 years ago #

    Here is my htaccess:

    AddHandler php5-script .php
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    # REDIRECTS OLD PAGES
    Redirect 301 /baixar/ http://taijiquan.pro.br/wordpress-dicas/
    Redirect 301 /videos-e-livros/ http://taijiquan.pro.br/livros/
    Redirect 301 /contato/ http://taijiquan.pro.br/eduardo/#contato
    # HOTLINKING
    RewriteCond %{HTTP_REFERER} !^$
    RewriteCond %{HTTP_REFERER} !^http://(www\.)?taijiquan.pro.br/.*$ [NC]
    RewriteCond %{HTTP_REFERER} !^http://(www\.)?taichichuan.pro.br/.*$ [NC]
    RewriteCond %{HTTP_REFERER} !^http://(www\.)?taijiquan.local/.*$ [NC]
    RewriteRule \.(gif|jpg|png|js|css|mp3)$ - [F]
    </IfModule>
    
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress
  6. mrmist
    Forum Janitor
    Posted 5 years ago #

    It looks like the redirects just aren't active or something.

    Have you tried setting permalinks to "default" and then back to your style?

  7. anatman
    Member
    Posted 5 years ago #

    Hey mrmist,

    I hadn't tried that - just did, but the problem remains. Looks like some redirection is working, just not working right.
    Do you know other troubleshooting measures?

    Thank you for your help.

  8. anatman
    Member
    Posted 5 years ago #

    I also tried right now to create abrand-new htaccess file. I changed WP to default permalinks, trashed my htaccess, created a new one, and chaned WP to my permalinks cutom structure. The file was written on by WP, but the problem persists.

  9. mrmist
    Forum Janitor
    Posted 5 years ago #

    I am out of ideas with this one I'm afraid.

  10. anatman
    Member
    Posted 5 years ago #

    I'm gratefull for your trying!
    I'm out of ideas too. I know very little f code, but it kind of looks like a regex thing in WP's rewrite engine. This is a wild guess, but why would i be able to access the posts by changing the category slug arbitrarily in the URL?

  11. rrryan
    Member
    Posted 5 years ago #

    I had a similar bizarre problem with my archives where only the Jan 09 Archives folder would display and the others would continually 403. Didn't matter what I tried (and I tried what seemed like everything) it would still happen. Turned out there was a static folder called "2008" in the blog root with subfolders "10", "11" etc. that would display instead and apparently interefere with the WP rewrites, serving a 403 Forbidden error when the directory listing request was denied. Just renamed that folder "2008-old" to test if that was it and voila, problem solved.

    I have no idea what that folder was doing there, but being new to WP and a little reckless I had been doing some dumb stuff and swapping plugins willy-nilly.

    Perhaps this is why you can get to the posts by inserting garbage - is there a static folder named "en" in the WordPress root that might be interfering if "en" is requested but not if something else is?

  12. anatman
    Member
    Posted 5 years ago #

    Hi rrryan,
    Thank you for your help.
    I don't have a "en" folder in the root. Anyway, i tried renaming a folder which name starts with an "e" to something else, but it didn't work... I also deleted a cache folder in the root, but that didn't work either.

  13. mrmist
    Forum Janitor
    Posted 5 years ago #

    Does this happen with the default theme too?

  14. anatman
    Member
    Posted 5 years ago #

    Yes, it does... just tried changing to default theme, the problem is still there.
    Thanks, mrmist!

  15. mrmist
    Forum Janitor
    Posted 5 years ago #

    I can't really understand this one. Unfortuantely to be able to log it as a bug it needs to be reproducable, otherwise it will be difficult to fix. And I've not been able to reproduce it, either.

  16. anatman
    Member
    Posted 5 years ago #

    Well, it is online anyway, live at my website! I am willing to keep it there (and not change the category name to something else, for example) so it can be verified...

  17. mrmist
    Forum Janitor
    Posted 5 years ago #

    Can you try turning off the canonicalism with the plugin here and seeing if it is still broken.

  18. anatman
    Member
    Posted 5 years ago #

    The plugin is running right now, but no change: still got the bug.

  19. mrmist
    Forum Janitor
    Posted 5 years ago #

    okidoke. I'll try to think some more about this later this week when I get some free time, unless someone else can help you first.

  20. anatman
    Member
    Posted 5 years ago #

    Thank you for your interest in this, mrmist.
    I will try to get some help in the IRC channel too when i have a day off, and if i make any progress i will post here.

Topic Closed

This topic has been closed to new replies.

About this Topic