From 9d72ddfbc73a2864ca629284140a7e8f6f46ad75 Mon Sep 17 00:00:00 2001 From: John McLear Date: Tue, 31 Jan 2012 14:15:36 +0000 Subject: [PATCH] Solves first part of #377 -- Swap order of title and pad name --- static/js/pad.js | 2 +- static/js/timeslider.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/static/js/pad.js b/static/js/pad.js index 0ed2a5d08..4fa46ac6b 100644 --- a/static/js/pad.js +++ b/static/js/pad.js @@ -197,7 +197,7 @@ function handshake() padId = decodeURIComponent(padId); // unescape neccesary due to Safari and Opera interpretation of spaces if(!isReconnect) - document.title = document.title + " | " + padId.replace(/_+/g, ' '); + document.title = padId.replace(/_+/g, ' ') + " | " + document.title; var token = readCookie("token"); if (token == null) diff --git a/static/js/timeslider.js b/static/js/timeslider.js index b02fd22f2..a36bd628a 100644 --- a/static/js/timeslider.js +++ b/static/js/timeslider.js @@ -73,7 +73,7 @@ function init() { padId = decodeURIComponent(urlParts[urlParts.length-2]); //set the title - document.title = document.title + " | " + padId.replace(/_+/g, ' '); + document.title = padId.replace(/_+/g, ' ') + " | " + document.title; //ensure we have a token token = readCookie("token");