// $Id: pmh.js,v 1.8 2006/07/25 21:35:06 krusch Exp $ -- built from pmh.source.js
// Copyright (c) 2006 IBM Corporation
// Owner: Corporate Webmaster (NUS_N_NIWWW)
document.write('<img src="//www.ibm.com/i/v14/t/print-header.gif" width="510" height="32" alt="" id="print-masthead"/>');

// Survey invitation
function ibmSurveySelect(){var dc=document.cookie;var prefix='ibmSurvey=';var begin=dc.indexOf(prefix);var now=new Date();if(begin==-1||(begin>0&&dc.indexOf("; "+prefix)==-1)){if(window.location.href.indexOf(".ibm.com")>0){document.cookie=prefix+now.getTime().toString()+"; path=/; domain=.ibm.com";}}}
ibmSurveySelect();

// List of patterns for inclusion and exclusion from search keyword tracking
// The first matching rule applies (true = track, false = don't track)
var ibmSearchTermRules = new Array(
	[ "/support/au/", false ],
	[ "//www.ibm.com/(.+/)?au/", true ]
	);
if(typeof RegExp!='undefined'&&typeof(encodeURIComponent)!='undefined'&&typeof(document.forms['search-form'])=='object'){for(var ibmSearchTermRule=0;ibmSearchTermRule<ibmSearchTermRules.length;ibmSearchTermRule++){var ibmSearchTermRegexp=new RegExp(ibmSearchTermRules[ibmSearchTermRule][0]);if(ibmSearchTermRegexp.test(window.location.href)){if(ibmSearchTermRules[ibmSearchTermRule][1]){document.forms['search-form'].onsubmit=function(){if(typeof sa_onclick=='function'&&typeof sa_gif=='string')sa_onclick("http://www.ibm.com/search/term/"+encodeURIComponent(document.forms['search-form'].q.value)+"/?re="+encodeURIComponent(window.location.href));return true;};}break;}}}

// Load OpenSearch description for compatible browsers
function ibmSearchOpensearchLink(){if(typeof window.external=='object'&&typeof window.external.AddSearchProvider!='undefined'&&typeof document.createElement!='undefined'&&window.location.hostname.indexOf('.ibm.com')!=-1){var link=document.createElement('link');link.setAttribute('rel','search');link.setAttribute('type','application/opensearchdescription+xml');link.setAttribute('href','http://www.ibm.com/search/opensearch/description.xml');link.setAttribute('title','IBM Search');var head=document.getElementsByTagName('head');if(head.length>0){head[0].appendChild(link);}}}
ibmSearchOpensearchLink();
