Demo | Download | Installation | FAQ | Screenshots / Video
AskApache Google 404 is a must-have WordPress plugin that uses some ajax and a couple tricks to display a very helpful and SEO Error Page. The default displays Google Search Results for images, news, blogs, videos, web, custom search engine, and your own site.
Updated: 01/26/2008
Install Time: 10 seconds to 5 minutes
Install Difficulty: Super Easy
Demo 404 Error Page
Upgrade Help:To get the new version to work if you are upgrading, Deactivate the old plugin, then remove the old plugins directory from the /wp-content/plugins/ folder, then install the new version.
Downloads
404.php Installation
- Upload
zip/tar.gzfile to the/wp-content/plugins/directory and unzip. - Activate the plugin through the ‘Plugins’ menu in WordPress.
- Go to your Options Panel and open the “AA Google 404″ submenu.
/wp-admin/options-general.php?page=askapache-google-404.php - Enter in your Google Search API Key and hit the “Update Key” Button. (Get One)
- Add the code to your 404.php template page by including
<?php if(function_exists('aa_google_404'))aa_google_404();?>in your main content area.
Frequently Asked Questions
Do I need a Google Account?>
Yes.
Do I need a 404.php template file?
Only if you want to use this for your error page.
My 404.php page isn’t being served for 404 Not Found errors!?
Add ErrorDocument 404 /index.php?error=404 to your .htaccess file.
What is a Google API Key?
How do I get a Google API Key?
Google 404 Screenshots
Loading Video… [dl]
More Info from Google
- AJAX Search API
- AJAX Search Wizards
- Developer Guide
- Code Samples
- Community Samples
- Knowledge Base
- AJAX APIs Blog
- Developer Forum
Related Articles
Click Image
09.13.07 at 7:23 am
AskApache Google 404 benutzt einen AJAX Code und einige Tricks um eine hilfreicheFehlerseite die bei einem 404-Server-Error ausgegeben wird. Das ganze soll SEO freundlich sein.
09.13.07 at 8:54 pm
Thank you.
09.13.07 at 9:27 pm
Hey all,
This plugin is amazing! It needs more Press! I will be including this on my next list of must have wordpress plugins. Great job with this, I have it working on my site if anyone wants to see another site with it. Very easy to install. just go to mustech.net/anythinghere and it will pop up.
09.14.07 at 9:29 am
Great plugin, thanks. Have installed on my blog: angry people.
How do you change the search bar preset?
Mine currently shows [co.uk or query] rather than [angrypeople.co.uk or query].
09.17.07 at 3:58 pm
Hey I love this plugin! It’s perfect for my 404 Error Page on WordPress!
09.18.07 at 10:02 am
Hi, I have installed this plugin on my blog but for some reasons, I think it doesn’t work if your permalink has the “date” on it, for example on my blog.
(1) If I typed “http://chenpn.com/funny-people/”, the 404 page will load perfectly OK.
(2) But if I typed “http://chenpn.com/2007/09/14/funny-people/”, the 404 page won’t load. But unfortunately, my permalink has the date in it.
Is this a bug?
09.18.07 at 10:52 am
pelf,
This is not a bug, the plugin is purposefully very simple to avoid bugs.. (new plugins are in the works), the problem is occuring because for whatever reason, your site is not displaying the 404.php page for pages that are prefixed similar to
/2007/09/14/ANYTHING.Instead of redirecting to
/index.php?error=404it redirects to/index.php?year=2007&monthnum=09&day=14.You can try adding this to your root .htaccess file to fix it.
09.19.07 at 8:36 am
Amazing work. Thanks.
09.19.07 at 3:50 pm
If you use htaccess file like that, maybe your robots.txt file will be not reconized by Google (this will be error “status 200 is trying to send by not existing document”). I met this situation, and removed the code ErrorDocument in the htaccess file.
PS: This plugin sounds excellent. I will try to test on my site. Thank you very much.
09.20.07 at 3:46 am
rilwis,
Only if your 404.php page isn’t setup the way WordPress recommends. All you need to do is add this to the very top of 404.php.
<?php ob_start(); header("HTTP/1.1 404 Not Found"); header("Status: 404 Not Found"); ?>09.21.07 at 2:16 pm
great plugin, thanks!
09.22.07 at 2:25 am
I just had one question. On the first tab and the Web tab, there is a section on the bottom called Sponsored Links. Is this hooked into your own google adsense account? If not, who is getting the money in relation to these sponsored ads?
09.22.07 at 12:23 pm
Jeffropt0,
That is a really great question that I had to search awhile to find. The answer is because this Search API is still so cutting-edge new, Google is the only one making any money from these Ads. It is still pretty beta now, but in the future it will very likely have the features we want. It is against the TOS to remove the ads, and currently you cannot hook your own AdSense account into the Search API. You can however use css to re-position the sponsored links.. like:
.gsc-control .gsc-ad-box {padding-top:100px;}According to Does the AJAX Search API contain advertising?
09.22.07 at 1:19 pm
Thanks for the reply AskApache. So far, those who have read my post about this plugin have installed it and have been pleased with the results.
09.25.07 at 6:49 am
Do you happen to know the output fields so I could add some css to the results list. Looks mad on a dark background.
Nice plugin I must add, worked out of the box. Cheers.
09.26.07 at 8:02 am
Hi there.
I’m having a small issue with your plug-in. The search results doesn’t seem to show. Any idea?
Also, how do i strip/replace the dashes from the search query?
Thanks for the excellent plugin.
10.01.07 at 11:44 am
Hi,
Thanks for this plugin.
But for some reason I’m only getting “loading…” and nothing else.
What could have I done wrong?
10.06.07 at 5:59 am
My problem is exactly same as the above!
10.06.07 at 12:01 pm
I too am having the same exact problem. Looks like 2.3 has borked this plugin.
10.06.07 at 1:10 pm
I Upgraded yesterday to 2.3 and I didn’t even get a blip of a problem from this plugin, seriously this plugin doesn’t do any database queries or anything other than print out some javascript.
I can only suggest that you deactivate the plugin prior to upgrading, and then just re-install it. Who knows, their might even be some improvements to the plugin..
The other thing I can offer is make sure you are using a correct Google API key and not just mine ;)
10.06.07 at 1:20 pm
Just wanted to say that I updated my API key for this plugin and it appears to be working again.
10.07.07 at 5:13 am
Ok I noticed one thing at least did change from 2.x to 2.3, check out wp-includes/canonical.php it is trying to guess what you are looking for and redirects.
if ( is_404() ) { $redirect_url = redirect_guess_404_permalink(); }10.26.07 at 7:11 am
i really like to see a more general 404 script which do not require wp.
so that i can install it to any cms, not limited to wp.
tia.
10.30.07 at 7:00 pm
List Of WordPress Plugins I Use » Jeffro2pt0.com
11.01.07 at 11:05 pm
Thats a great list of helpful WordPress Plugins jeffro2pt0, thanks!
11.02.07 at 5:53 am
No problemo. The ask apache plugin write I did is the second most popular article on my blog lol.
11.02.07 at 9:31 am
Once you upgrade WordPress past 2.1 you will need to edit a file to make sure your.
404 page is served correctly.
Open
/wp-includes/canonical.phpand do the following.Add
function redirect_canonical($requested_url=NULL, $do_redirect=true) { global $wp_rewrite, $posts, $is_IIS; if ( is_feed() || is_404() || is_trackback() || is_search() || is_comments_popup() || is_admin() || $is_IIS || ( isset($_POST) && count($_POST) ) || is_preview() )Add
if(false!==strpos($wpdb->escape(get_query_var('name')),'404')) return false;function redirect_guess_404_permalink() { global $wp_query, $wpdb; if ( !get_query_var('name') ) return false; if(false!==strpos($wpdb->escape(get_query_var('name')),'404')) return false; $where = "post_name LIKE '" . $wpdb->escape(get_query_var('name')) . "%'";11.02.07 at 5:34 pm
Google Custom Search: Custom Search Results Overlay
11.06.07 at 10:39 pm
Thanks! This is one plugin that I am going to share with all my readers
11.08.07 at 12:33 am
what a great plugin!
easy to install, easy to use, easy to configure, i’m using it now!
thank you…
11.08.07 at 5:20 pm
What exactly has changed in this latest release?
12.10.07 at 11:16 pm
i love it!
cheers!
:)
12.25.07 at 8:37 am
I’m looking for a bit different functionality. We’re coming from Joomla, and the URLs they use lacked any title/stub at all (
/content/view/%article-id%) for example.So, the plugin isn’t going to help in terms of migrating from Joomla… since it’s just going to search the WordPress site for “
content view %article-id%” and come up with nothing.Is there a way to have it grab the Google Search Query from the referring URL? I’d much rather pass along what the user entered as their search query… as that’s more likely to dig up relevant content in the site itself.
12.27.07 at 12:21 pm
Ive installed this on one of my friend’s blogs and he uses i3Theme 1.2 as a his wordpress theme and he uses
wp 2.3.1.I activated this plugin and put the right Google API code. I also edited the themes 404.php. But still when I press the Test Your 404 thing, it just show the frontpage but when i type in this
site.com/index.php?error=404then it shows the googles stuff…What did I do wrong?
01.11.08 at 1:04 pm
This is fabulous, thank you!
01.16.08 at 3:44 am
[...] AskApache Google 404 AskApache Google 404 is a must-have WordPress plugin that uses some ajax and a couple tricks to display a very helpful and SEO Error Page. The default displays Google Search Results for images, news, blogs, videos, web, custom search engine, and your own site. [...]
01.21.08 at 2:15 pm
thanks for 404 plugin!
01.26.08 at 8:45 am
Hey Hi :) I just installed your 404 plugin - great work and thankyou, thankyou, thank you,
my second day at blogging and still trying to get my head around everything, found your spot during my travels and though I must say - most of what you have onyour iste flies right over my head, but still makes for very interesting reading, I’m sure I’m going to learn a lot here still especially the htaccess stuff and rewrites.
Melanie
01.26.08 at 2:42 pm
Why did you decide to change the file names once again in this latest version. I’m always having to figure out which is which when I upgrade. Why can’t this be a simple overwrite process.
01.26.08 at 2:54 pm
I managed to upgrade your plugin but now the search does not function anymore. I’ve tried to get a new API key but even that doesn’t solve the problem. What else should I try>
01.26.08 at 3:29 pm
Hi,
thanx a lot, my 404 page now looks nicer than some of my normal pages :-)
01.27.08 at 4:17 pm
I have no idea how I fixed it except that I was just playing around trying various things and eventually, I clicked on the Reset Options to make the thing go back to default and it finally worked. Looks like for whatever reason, the api key had something to do with the problem. Looks like the whole key was not properly added into the plugin options even though I swear I copied and pasted the google API key about 100 times. At any rate, all is well it seems.
01.28.08 at 11:18 pm
AskApache,
I had the same problems as Jeffro Above. Unfortunately, I could not get it to work. I transitioned back to 4.1 and it works again.
Here is some troubleshooting info:
I’m running wordpress 2.3.2
The Xhtml appeared on my “404″ page with your version newest version of 4:
Wait a sec, I might be able to help…
That is I saw the Wait a sec, I might be able to help… and then…
Nothing loaded after that.
I tried a new Google API key twice, defaulted the options twice and that did not fix it.
When I reverted back to 4.1, it all worked again.
FYI,
J. Pisano -mustech.net
01.29.08 at 8:10 am
I upgraded to the latest 4.2 version and it stopped working. I cleared everything and installed from scratch and still no go. So I reinstalled 3.0 and it worked again. I don’t know what’s wrong.
02.02.08 at 7:49 pm
Hi, tnks for the great plugin.
Just a question.
Can I cut off the results for the Web-Blog-video-immagine-cse ? i would like to delete that folder …
thanks
02.05.08 at 11:25 pm
I love this plugin! Unfortunately, it doesn’t work “right out of the box” with my template. Nothing else has, so I know it isn’t because of the plugin - apparently, it’s just an odd template. The template didn’t come with its own 404 page, but I’ve tried customizing the plugin and now MOST of the results are showing up properly. Unfortunately, the “404″ part is still where the left sidebar should begin, and the sidebar content isn’t appearing ’til after the plugin-generated content is finished in the main container of the page.
I realize that might not make any sense, but you can see what I mean at http://technomom.com/404/test-404-page-plugin-askapache-wordpress-plugin-search-engine.html
Any suggestions?
Thanks!
Cyn
02.08.08 at 6:27 am
Just a question.
Can I cut off the results for the Web-Blog-video-immagine-cse ? i would like to delete that folder …
thanks
02.23.08 at 6:03 am
Hi,
You are using google Ajax search API, my question is can we use a single google api id for wordpress plugin development? A little off topic, but I will really appreciate your answer.
02.23.08 at 7:30 am
Nice plugin, thanks AskApache.
02.23.08 at 6:53 pm
Nice plug-in, BUT it screws up my template. It moves the second sidebar down under the text for the plug-in which makes it look pretty strange. I have tried changing the CSS to correct for this, but my changes have done nothing.
So right now your plug-in is not usable. Undoubtedly some operator error somewhere, but I don’t know where so I have deactivated the plug-in until I hear a solution.
03.04.08 at 10:15 pm
have no idea how this works… i have my blog hosted on another folder:
clinebellmusic.com/blog
does this mean i need to do something to the plugin so that it looks in the right directory? it just gives me a page not found:
Not Found
The requested URL /404/test-404-page-plugin-askapache-wordpress-plugin-search-engine.html was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Please anyone help!!! :)
03.06.08 at 2:29 pm
Hello to everybody.
Is this plugin processing only 404 errors?
How can I make it process other errors?
Thank u.
03.15.08 at 7:57 pm
The problem I have it is that GOOGLE API doesn’t me using permalinks! It thinks it is another directory on the website :(
04.13.08 at 10:03 am
Thanks a lot for this amazing plugin.
Best regards.
04.26.08 at 9:25 pm
Thank you VERY much for this plugin! I hope visitors get alot better experience because of it and I truly believe they will. :)
Wish this had been around earlier and I do hope it becomes more prevalent!
05.02.08 at 4:01 am
[...] AskApache Google 404 : Personnalise la page erreur 404, quand une page est supprimer ou quand il y a une erreur de frappe dans l’URL. Ce plugins modifie cette page est intègre le champ de recherche de Google indexant uniquement votre site et proposant dès son affichage un ensemble d’articles ou de pages qui pourraient correspondre à la recherche du visiteur. [...]
05.07.08 at 10:07 pm
I just installed it (in WP.2.5.1) and it works perfectly, and I’m very grateful for your plugin. There is just one minor snag, more aestetic than important..
At the top of the administrative part, after the phrase “SEO Boost from 404 Plugin? Focus on humans” and before the test-search box, there is a bunch of garbage code visible, looking like this (a snippet only):
It seems like it is trying to translate something into swedish (which is my language) and is failing miserably :)
However - everything works perfectly at the front end, and the documentation tells everything I need to know, so I don’t think there is any emergency - just wanted to let you know.
05.11.08 at 8:01 pm
Hi, first of all thanks for the plugin, this one is really cool. I have some problems, though.. The first one is that the plugin expects the blog to be in the root directory, there is no option to change that (mine is under the “blog”-folder”..)
Second I get the weird message: WordPress database error: [Can't find FULLTEXT index matching the column list] Could you help here what columns are necessary to change?
Thanks alot!