Archive for the ‘SEO, Search, Google’ Category

Smarty SEO plugin: meta_tag

3rd April

2009

Carolv

Presenting the meta_tag plugin for the Smarty templating engine!

Click here to download block.meta_tag.txt

Click here to download outputfilter.meta_tag.txt

This plugin allows you to change the page title and meta tags from any template used to generate page output.

Purpose

Typical web page display scenario:

Web page “Home” consists of Smarty templates:

  • header.tpl – generic page header, HTML declaration, <HEAD> & <BODY> tags etc.
  • navigation.tpl - site navigation.
  • home.tpl – the main content for a given page, in this example “home”.
  • footer.tpl – the page footer – closing </HEAD> & </BODY> tags, javascript tracking etc.

In this example, the page title and meta data would be in header.tpl, whether as Smarty variables:

<title>{$page_title}</title>

…or hard-coded values:

<title>Hello world!</title>

Using the meta_tag plugin, title and meta tag values can be updated from any other template used to generate the page.

The following example contained in footer.tpl would add “Product description” to the page title:

{meta_tag type=’title’ method=’add’}Product description{/meta_tag}

The following example contained in home.tpl would replace the page title with the text “Important business report”:

{meta_tag type=’title’ method=’replace’}Important business report{/meta_tag}

The following example contained in footer.tpl would add the text “jacket,blue,leather” to the meta keywords:

{meta_tag type=’keywords’ method=’add’}jacket,blue,leather{/meta_tag}

So… what’s the point?

Often when you’re displaying dynamic data across several templates it isn’t practical to customise the page title and meta information using Smarty assign(). Also,the logic used in templates processed after the page header might contain information which would be useful to reference in the header.

Caveat

It’s preferable to call load_filter just once per output, BEFORE the instruction to display() or fetch():

$smarty->load_filter(‘output’, ‘meta_tag’);
$smarty->display(“template.tpl”);

In a scenario where multiple templates are used, they should all be contained within one container template, to ensure the output filter isn’t called repeatedly. In the above example, template.tpl might be:

{include file=’generic/header.tpl}
{include file=’generic/navigation.tpl}

{* load main page body – filename is contained within var $template*}
{include file=’`$template`}
{include file=’generic/footer.tpl}

Installation:

Click here to download block.meta_tag.txt

Click here to download outputfilter.meta_tag.txt

Change the file extension on both files to .php, then copy them to your Smarty plugins directory (smarty/plugins). Detailed usage instructions can be found in the comment block of each file.

Google Lively

10th July

2008

Lively, currently in beta, is Google’s answer to Second Life. The downloadable application allows you to create rooms, decorate them to your liking, then make and invite friends over. Of course, you’re far better off actually doing these things in real life, but if you have poor personal hygiene and/or no friends you’re sure to find it very rewarding.

Googlelively

Google says bye to 300 staff

4th April

2008

Following its acquisition of DoubleClick, Google is cutting 300 staff. More info from the Guardian.
Googleplex

Google takes on Wikipedia

15th December

2007

Search behemoth Google has announced a new tool to rival Wikipedia. Currently known as “knol” (it stand for a unit of knowledge, apparently), its object is “to encourage people who know a particular subject to write an authoritative article about it.” This sounds very much like Wikipedia, although some would argue that you need no nothing about a subject to be a Wikipedia contributor (despite credible evidence that suggest otherwise).

Google has yet to announce when the general public will get to experience “knol”, but you can find out more and see a screenshot of the prototype here.

Ask.com is rubbish

6th November

2007

Ask.com has launched a UK map service similar to offerings from Google and Microsoft. The postcode for our office brings up the following result:

Askmapsrubbish

Cheers Ask.com! So, Albemarle Way (London EC1V 4JB) is in the middle of the Gobi Desert? On a pair of Holly Johnson’s chinos? Oh, I despair! Ask.com, drop and give me twenty!

Google to take on Second Life

26th September

2007

Google is rumoured to be planning a rival to the 3D virtual world Second Life, scheduled to be launched late 2007.

If this is true (and this being the internet, you really never know), it’ll be a surprising departure for Google, a company that has built its reputation on solid, reliable, consumer-orientated online applications. Second Life, whilst undoubtedly a great money spinner for Linden Lab, is a controversial, marriage-wrecking, sad, barely-legal, addictive beast that keeps people from pursuing their non-avatar based, real lives.
Secondlife1-1

Microsoft Tafiti Beta

22nd August

2007

I’ve been playing around the Tafiti beta, which uses Microsoft’s Silverlight technology. The system is little more than a proof of concept at the moment, but I must confess, I’m impressed. It offers easy navigation between web, rss, image, news and book seaches, and boasts an interactive tree view (which is pretty much useless but looks fantastic).

Tahiti

Tahiti is my first Silverlight experience, and from first impressions, it seems identical from Flash from a user experience perspective. It remains to be seen whether it’ll prove to be a serious alternative in the long run.

Google keen on mapping mashups

11th July

2007

Following the appearance of thousands of Google Maps mashups, Google have introduced a new technology to encourage further user interaction. The “mapplets” (mini-webpages inside an IFrame) can be combined to create custom mashups: for example, you could display information on house prices, crime rates and cemeteries simultaneously, with built-in features such as driving directions thrown in for good measure.

The following YouTube video shows the system in use:

You can find out more about mapplets here:

http://www.google.com/apis/maps/documentation/mapplets/

More info on the Google Earth/Maps blog.

The service will be live to the public sometime today, following months of private beta.

Search result face off

13th June

2007

A website has recently launched that allows surfers to search Yahoo and Google simultaneously, providing side by side results for instant comparison.

The website, searchboth.com, has been developed by IdeaLabz.com who claim it to be a first. In view of the erstwhile existence of meta search engines such as dogpile.com, we presume it is referring to its somewhat innovative display view rather than the simultaneous querying of multiple search engines.
To be honest though, I can’t see it catching on…

Google trials face recognition

31st May

2007

As reported on Ars Technica, Google seems to have sneakily added some rudimentary face recognition filtering to its image searches.

Search for ‘ferrari’ and you’ll find, as expected, a multitude of images of Ferrari cars. However, append ‘imgtype=face’ to the end of the url string and see only images of people!

What will they think of next?