How to handle 404 in Graphene?
I am looking for a trick, a solution to handle eventual 404 messages.
Let’s say, I have made a misstake when typing the title of the post. Later on I correct it, so, the permalink will change, as well… and people, who bookmarked the post… will get 404.
Or, someone misstypes the page’s address within the web site… and would get 404.
So, for whatever reason the address within my site is not found I would like to … either redirect the visitor to the start page, or find the possible page what he might be looking for.
What do you suggest? How may I make sure, that there is no 404 message ever…
Later on I correct it, so, the permalink will change, as well… and people, who bookmarked the post… will get 404.
No. The permalink will only change if you edit. See this post, where I changed the title but the permalink is the still the same:
or find the possible page what he might be looking for
Graphene will do an automatic search for you. For example, if you typed in the above link, but misspelled “link” as “ink”, you would get this:
That’s just a test blog, so the few posts there aren’t very distinct from one another, so you get a lot of results. But once you have a fair number of posts that are distinct from one another, it works quite well.Mod
Well, Ken… It used to be possible. 🙂
I was using these plugins:
Both eliminated 404. 🙂
Yes, you are right. I made a misstake. I know, permalink changes only if I change it. However, it happened already to me, that I misspelled a name in the post’s title, and corrected it later on. And, yes, indeed, I corrected the permalink, as well… to make sure, that Google finds the correct name.
So, if I understand well, “Graphene will do an automatic search”… This is excellent!
However, – I have just tested it – 404 still may happen. This is what I would like to handle… may be via Graphene itself, or with the help of an appropriate plugin.
THANKS for your friendly, quick and useful answers.
However, they have not been updated for the new WP 3.3.1. Otherwise, they used to be nice.
AnonymousMarch 27, 2012 at 2:44 am #26971
Moved to support. Please post in the correct section next time.Admin
@Tamas, the 404 respond code is there for a reason. It informs the clients (which includes your site’s visitors, search engines, and myriad of other clients) that whatever resource they’re requesting, it can’t be found. Based on this, different clients will respond in different ways.
There was even a case previously (quite a long time ago) when Google actually penalised a site using the Graphene theme for not returning the proper 404 response when a content is not found (and obviously this has been fixed since then).
Therefore, totally eliminating 404 messages in your website is highly not recommended, especially when you’re doing this just to correct a mistake in a single post. It’s like they say, why drop a nuclear bomb when only a precision strike is necessary?
The proper and better way to handle your situation is to use 301 Redirect. In HTTP client-server model, the 301 response code means Moved Permanently.
Respectable search engines will then most likely transfer the ranking from the old page (if any) to the new page, and phase out the old page from search results. If your visitors follow their bookmark of the old page, they’ll simply be redirected to the new page. Simple, and correct.
OkÃ©, I understand, that eliminating 404 is not the right path to walk.
It is nice from you, that you explained how do you see it. Thnaks, again.
OkÃ©, I learn.
(However, the nuclear bomb thing… well… I felt it rather violent and inappropriate.)
So, so question now… how to use 301? As a gentle solution… ?
Thanks, and have a peaceful day.
TamasAdminQuote:(However, the nuclear bomb thing… well… I felt it rather violent and inappropriate.)
Oh, don’t be offended. It’s one of the most popular way of explaining SOPA to the public during the massive online protests. It’s certainly not directed to you or anyone else.
The easiest way to implement the 301 Redirect is by using the
.htaccessfile. See this page for guidance:
Viewing 10 posts - 1 through 10 (of 12 total)
- You must be logged in to reply to this topic.