mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-05-04 22:27:10 -04:00
Merge ae73b1101a
into f465ebaab9
This commit is contained in:
commit
c074994f66
1 changed files with 6 additions and 1 deletions
|
@ -63,6 +63,7 @@
|
|||
//get the padId out of the url
|
||||
var urlParts= document.location.pathname.split("/");
|
||||
padId = urlParts[urlParts.length-2];
|
||||
padId = unescape(padId); // unescape neccesary due to Safari and Opera interpretation of spaces
|
||||
|
||||
//set the title
|
||||
document.title = document.title + " | " + padId;
|
||||
|
@ -271,7 +272,11 @@
|
|||
<!-- termporary place holder-->
|
||||
<a id = "returnbutton">Return to pad</a>
|
||||
<script>
|
||||
$("#returnbutton").attr("href", document.referrer);
|
||||
if(document.referrer.length > 0 && document.referrer.substring(document.referrer.lastIndexOf("/")-1,document.referrer.lastIndexOf("/")) === "p") {
|
||||
$("#returnbutton").attr("href", document.referrer);
|
||||
} else {
|
||||
$("#returnbutton").attr("href", document.location.href.substring(0,document.location.href.lastIndexOf("/")));
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue