WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Changed permalinks - now I can't access my blog (18 posts)

  1. Lassefm
    Member
    Posted 6 years ago #

    I wanted to change my permalink structure from http://example.com/?p=N to http://example.com/category/post-name/.

    So I changed the structure in my settings to /%category%/%postname%/.

    After I saved my changes the blog doesn't work. :( I can't access my website and I can't even access wp-login.php anymore so I can't change it back.

    I hope someone can help and tell my why the problem occured and how to reset it. Thanks.

  2. Roy
    Member
    Posted 6 years ago #

    I made the same mistake. Make the structure example.com/category/post-id/postname and your problem is most likely solved.

  3. Lassefm
    Member
    Posted 6 years ago #

    But how do I change it? I can't login to my wordpress blog via wp-login.php so I am kinda stuck. I can access the files on my ftp-server, though, so is there a specific file I can edit there to reset the permalinks structure?

  4. Roy
    Member
    Posted 6 years ago #

    You got THAT far...? I noticed in time and could still use the "back" button. Weird, though, because the admin panel has nothing to do with the permalinks. I'm afraid I have no tips regarding FTP or the Control Panel... Maybe you can have a look at the htaccess? I'm not sure if permalinks has something to do with that, but they DO require 'mod-rewrite'. Hopefully that gives you an idea, otherwise I hope that somebody else has a better idea...

  5. Lassefm
    Member
    Posted 6 years ago #

    Yeah I got that far :/ tried to use the back button, but it wouldn't load the previous page. It is strange that it affects the admin panel, I don't get that either...

    I am pretty clueless right now, so I hope someone can help. Thanks for the reply though Gangleri

  6. Roy
    Member
    Posted 6 years ago #

    Well, it has definately something to do with your htaccess file. If you go to your control panel and open it in a viewer, you may see some url-rewriting lines that you can delete and try to login again. I have never done such a thing, but here's something you can try and hopefully there's someone to talk you through it (or with a better idea!).

  7. WildBil2Me
    Member
    Posted 6 years ago #

    Lassefm,

    Can you provide a URL where this is happening? If it is the permalink structure then you can manually change this by going into the WordPress database by using something like phpMyAdmin - it's a little complicated but not too hard.

    The strange thing, though, is that you shouldn't be blocked from accessing your /wp-admin or /wp-login.php files - at least not necessarily.

    If you could share the URL it might shed light on the issue.

  8. Samuel Wood (Otto)
    Tech Ninja
    Posted 6 years ago #

    Changing the permalinks should not block you out of wp-admin no matter what you do. wp-admin doesn't use permalinks.

    If you're locked out of wp-admin, try renaming your .htaccess file temporarily.

  9. WildBil2Me
    Member
    Posted 6 years ago #

    "/%category%/%postname%/" is actually perfectly acceptable code to use for your permalink structure too.

    Chances are there's an underlying problem of some sort.

  10. Lassefm
    Member
    Posted 6 years ago #

    WildBil2Me: The site I'm running the blog on is http://www.spend.dk . After I changed the permalinks I could not access the blog OR the wp-admin.php file. I have tried resetting the database by deleting all the tables in it (blog is still under construction so not too big a loss) but with no luck. So now my database is empty.

    Otto42: I have been looking for my .htaccess-file since Gangleri told me about it, but can't seem to find it. It should be in my root directory, right? Can it be a hidden file of some sort? I am using filezilla, can't find anywhere where I can tell it to show hidden files..

    As most of you have stated, the admin files should not be affected - but somehow they did.

  11. Roy
    Member
    Posted 6 years ago #

    Hi all, the Codex that I referred to advises to add 'something numerical' to the permalink and wonders if that also goes for WP 2.x.x, I think it is save to say after this thread that it does. When I tried to do the same a few months back (2.1.3 or before I guess), I was also blocked from my admin panel, but I just hit the "back" button and undo what I did. Somehow these things seem related, but I don't know how. In any case, Lassefm has a serious problem. I also thought about deleting the htaccess (renaming may indeed be an even better idea) temporarily. Would that solve his problem?

  12. Lassefm
    Member
    Posted 6 years ago #

    Just found the 'show hidden files'-button in FileZilla. But there is no .htaccess-file to be found. But according to the link provided by Gangleri, I shouldn't necessarily have one, if I understand it right.

  13. Roy
    Member
    Posted 6 years ago #

    If you don't, your pretty permalinks won't work. In any case, the .htaccess is supposed to be in your root directory. I cannot see it using FTP, but I can when I check my files in my control panel. (Btw, I'm off for tonight, good luck with everything.)

  14. moshu
    Member
    Posted 6 years ago #

    At this moment your WP is not installed. The address you gave above displays the installation page... Install it quickly before someone else clicks on it :)

  15. Lassefm
    Member
    Posted 6 years ago #

    Wow. I contacted my web host about the issue some 7 hours ago, and now they have fixed it. I now have a clean installation of WordPress, so I can use the blog again.. Yay! But I still don't know why the permalinks messed up my admin panel.

    I'll leave the thread open for a bit if people want to discuss the issue. Thanks all for the help.

  16. moshu
    Member
    Posted 6 years ago #

    Make sure your server/host has all the requirements for Using_Permalinks.

  17. haunty
    Member
    Posted 5 years ago #

    I have the same problem. I changed my blog description and the permalink options and now I'm completely shut out of my blog, can't even access login panel. Would you tell me how to change this in phpMyAdmin?

  18. haunty
    Member
    Posted 5 years ago #

    I've just created a .htaccess and uploaded it thru ftp. I can login now. The problem is whenever I try to cahnge my permalinks option back to default and save changes I get the same problem: error and redirection to my host's site.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags