Files
9minutes/public/javascripts/title.js
T
2011-07-02 17:31:04 +02:00

18 lines
507 B
JavaScript

function changeDocumentTitle(to, special)
{
special = (typeof special == "undefined" || typeof special == "boolean") ? null : special;
titleLink = (to.substring(to.length-1, to.length) == "/") ?
to.substring(0, to.length-1) : to;
titleLink = titleLink.replaceAll("/","");
if(titleLink == "artists")
{
titleLink = special;
special = null;
}
document.title = documentTitle + " » " + titleLink.urifyAll();
if (special) document.title += " » " + special.urifyAll();
}