Post by Dhaupin » Fri Jul 04, 2014 12:44 am

https://support.google.com/webmasters/answer/136085

This adds a search box to the 404 page that looks for similar terms. It also claims that it will add "did you mean" style similar links eventually and alternative urls. It uses javascript to do this and it seems like a rather robust script....neat.

Add it somewhere on your catalog/view/theme/default/template/error/not_found.tpl 404 page like before the <div class="buttons">...using config->get you can make it multistore compatible. Change the 'en' to whatever language you use, or use a var to put in the current site users language:

Code: Select all

<script type="text/javascript">
	var GOOG_FIXURL_LANG = 'en';
	var GOOG_FIXURL_SITE = '<?php echo $this->config->get('config_url'); ?>'
</script>
<script type="text/javascript"
	src="//linkhelp.clients.google.com/tbproxy/lh/wm/fixurl.js">
</script>
Hope that helps, thanks

https://creadev.org | support@creadev.org - Opencart Extensions, Integrations, & Development. Made in the USA.


User avatar
Active Member

Posts

Joined
Tue May 13, 2014 3:45 am
Location - PA
Who is online

Users browsing this forum: No registered users and 5 guests