if (alist[i].innerHTML.indexOf('<span class="link-'+fileTypes[type]+'"></span>')===-1&&alist[i].innerHTML.indexOf('<img')===-1&&isFileType(alist[i].href,fileTypes[type])&&isOwnDomain(alist[i].href)){
icon=document.createElement('span');
icon.className='link-'+fileTypes[type];
alist[i].appendChild(icon);
}
// mark pdf/doc/txt links with link-pdf/link-doc/link-txt classes
if (alist[i].innerHTML.indexOf('<span class="link-'+fileTypes[type]+'"></span>')===-1&&alist[i].innerHTML.indexOf('<img')===-1&&isFileType(alist[i].href,fileTypes[type])&&isOwnDomain(alist[i].href)){
icon=document.createElement('span');
icon.className='link-'+fileTypes[type];
alist[i].appendChild(icon);
}
}
}
catch(err){}
})();
}
catch(err){}
}
// Disable the global search if a page defines a local search.
// Can also be disable by adding class 'no-global-search' to the body element.
// Array of search box definition objects, specify inputNode, defaultText (optional, default ''), errorText (optional, default 'Please enter a search term')
varsearchBoxes=[
{inputNode:document.getElementById('global-searchbox')},// in global masthead
{inputNode:document.getElementById('local-searchbox')},// in local masthead
{inputNode:document.body.className.indexOf('front')!==-1?document.getElementById('query'):null},// on home page
{inputNode:document.getElementById('people-groups')?document.getElementById('people-groups').getElementsByTagName('input')[0]:null}// on people and group page
];
// Add error alerts for 'no input' on search boxes.
// Todo: this, perhaps, shoule be moved to a value-add script file
// Array of search box definition objects, specify inputNode, defaultText (optional, default ''), errorText (optional, default 'Please enter a search term')
varsearchBoxes=[
{inputNode:document.getElementById('global-searchbox')},// in global masthead
{inputNode:document.getElementById('local-searchbox')},// in local masthead
{inputNode:document.body.className.indexOf('front')!==-1?document.getElementById('query'):null},// on home page
{inputNode:document.getElementById('people-groups')?document.getElementById('people-groups').getElementsByTagName('input')[0]:null}// on people and group page
'<p>EMBL-EBI in Hinxton is one of five EMBL locations across europe.<br/> <a href="//www.ebi.ac.uk/about" class="small readmore">More about EMBL-EBI</a></p>'+
'<p>EMBL-EBI in Hinxton is one of five EMBL locations across europe.<br/> <a href="//www.ebi.ac.uk/about" class="small readmore">More about EMBL-EBI</a></p>'+