• Resolved SashainSydney

    (@sashainsydney)


    Great plugin Avril – many thanks!

    I noticed wp-login and wp-admin redirect to different pages. login seems to go to today’s archives and admin creates a 404. Is that necessary? Couldn’t they just go to 404.html?

    Or, perhaps one might like to redirect to the homepage or some other page.

    How might that best be done?

    Best,

    Sasha

    https://www.ads-software.com/plugins/rename-wp-login/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Ella

    (@ellatrix)

    They’re both supposed to be returning a 404 page. If a 404.php template exists in your theme, it will use that. If not, it will use index.php and the conditional tag is_404() will return true.

    It’s weird that your admin goes to your archives, both use the same function. Can you give me a link please?

    Thread Starter SashainSydney

    (@sashainsydney)

    Sure:

    https://www.alexanderkreisler.net/blogg/wp-admin/
    https://www.alexanderkreisler.net/blogg/wp-login/

    wp-admin appears to break the theme at the top…not sure why and where yet.

    Cheers,

    Sasha

    Plugin Author Ella

    (@ellatrix)

    I get the same page for both links… A 404. (Except for the bit at the top that’s broken.)
    That’s because the body still has the class “admin-bar” in it. (triggered by is_admin().) I’ll try to fix it with the next release.

    Thread Starter SashainSydney

    (@sashainsydney)

    Hm…and <title> is different too.

    The right 404 page should look like this https://www.alexanderkreisler.net/blogg/nothing-here/

    Still, a good idea for a plugin and works pretty well.

    Many thanks,

    Sasha

    Plugin Author Ella

    (@ellatrix)

    For me it’s all the same… same title in the head, same title in the body, same content… Could you take a screenshot or something?
    Btw, the weird bit an the top of wp-admin is now gone. Did you change anything about that?

    Thread Starter SashainSydney

    (@sashainsydney)

    Hallo Avryl,

    Didn’t change a thing, I swear ??

    You’re right, pages are essentially the same, custom 404 page. But by calling slightly different functions, they come out differently.

    Screenshot:

    https://www.pixhost.org/show/3757/18730382_redirect-screenshot01.png

    Me thinks, login is okay as is. Admin’s got something, but you knew that.

    I was only wondering if calling a 404 page rather than a function might be preferable. Perhaps even give users the option to call 404.html or index.html? But that’s just my two Cents…really nice plugin!

    Greets from Down Under,

    Sasha

    Plugin Author Ella

    (@ellatrix)

    Oh, now I see the title too… I was comparing wp-login to nothing-here.
    Well the plugin calls 404.php from your theme. It doesn’t make much sense to have an option to call 404.html because almost no one has that. The best thing you can do then is redirect 404.php to your custom 404 page.
    But I see the problem with the wp-admin page. I’ll take a look at it.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How best to redirect to 404.html?’ is closed to new replies.