Make WordPress Core

Opened 12 months ago

Closed 12 months ago

Last modified 5 months ago

#60866 closed defect (bug) (worksforme)

Non existing 404 url open homepage when using static homepage feature

Reported by: ashvinblog's profile ashvinblog Owned by:
Milestone: Priority: normal
Severity: normal Version: 6.4.3
Component: General Keywords:
Focuses: Cc:

Description

When using static homepage feature, non existing page urls open homepage instead of 404 page.

For example,
Your site is https://example.com
You set static homepage instead of default latest post.

Now, if someone visit url,
https://example.com/page/999999 or https://example.com/?s%2525252527993994-%
This will display homepage with status 200, instead of 404 page.

Change History (4)

#1 follow-up: @pratiklondhe
12 months ago

  • Resolution set to worksforme
  • Status changed from new to closed

hi, can you help with which theme you are using? If your theme does not have a template for 404.php it will by default redirect to the index.php template

#2 @ashvinblog
12 months ago

currently using https://wordpress.org/themes/astra/ theme
but also tested issue in wordpress default theme

#3 in reply to: ↑ 1 @ashvinblog
12 months ago

Replying to pratiklondhe:

hi, can you help with which theme you are using? If your theme does not have a template for 404.php it will by default redirect to the index.php template

currently using https://wordpress.org/themes/astra/ theme
but also tested issue in wordpress default theme

#4 @desrosj
5 months ago

  • Component changed from Rewrite Rules to General
  • Milestone Awaiting Review deleted

Hi @ashvinblog,

Welcome to Trac!

Sorry that this one fell through the cracks. I've tested with a default WordPress install and I am shown a 404 page when following your steps. If you're still experiencing the issue, please reach out to Astra's support or post in the WordPress.org Support Forums.

Note: See TracTickets for help on using tickets.