added proper embed parameter support, fixes #116

pull/122/merge
Peter 'Pita' Martischka 2011-08-23 18:36:38 +01:00
parent f571ed3554
commit 7b8d48467f
3 changed files with 11 additions and 11 deletions

View File

@ -231,9 +231,9 @@ var padimpexp = (function()
init: function()
{
// build the export links
$("#exporthtmla").attr("href", document.location.href + "/export/html");
$("#exportplaina").attr("href", document.location.href + "/export/txt");
$("#exportwordlea").attr("href", document.location.href + "/export/wordle");
$("#exporthtmla").attr("href", document.location.pathname + "/export/html");
$("#exportplaina").attr("href", document.location.pathname + "/export/txt");
$("#exportwordlea").attr("href", document.location.pathname + "/export/wordle");
//hide stuff thats not avaible if abiword is disabled
if(clientVars.abiwordAvailable == "no")
@ -249,8 +249,8 @@ var padimpexp = (function()
{
$("#exportpdfa").remove();
$("#exportworda").attr("href", document.location.href + "/export/doc");
$("#exportopena").attr("href", document.location.href + "/export/odt");
$("#exportworda").attr("href", document.location.pathname + "/export/doc");
$("#exportopena").attr("href", document.location.pathname + "/export/odt");
$("#importexport").css({"height":"142px"});
$("#importexportline").css({"height":"142px"});
@ -259,11 +259,11 @@ var padimpexp = (function()
}
else
{
$("#exportworda").attr("href", document.location.href + "/export/doc");
$("#exportpdfa").attr("href", document.location.href + "/export/pdf");
$("#exportopena").attr("href", document.location.href + "/export/odt");
$("#exportworda").attr("href", document.location.pathname + "/export/doc");
$("#exportpdfa").attr("href", document.location.pathname + "/export/pdf");
$("#exportopena").attr("href", document.location.pathname + "/export/odt");
$("#importform").get(0).setAttribute('action', document.location.href + "/import");
$("#importform").get(0).setAttribute('action', document.location.pathname + "/import");
}
$("#impexp-close").click(function()

View File

@ -96,7 +96,7 @@
</a>
</li>
<li class="separator"></li>
<li id="timesliderlink" onClick="document.location = document.location+ '/timeslider'">
<li id="timesliderlink" onClick="document.location = document.location.pathname+ '/timeslider'">
<a title="Show the history of this pad">
<div class="buttonicon" style="background-position:0px -218px"></div>
</a>

View File

@ -271,7 +271,7 @@
<!-- termporary place holder-->
<a id = "returnbutton">Return to pad</a>
<script>
$("#returnbutton").attr("href", document.location.href.substring(0,document.location.href.lastIndexOf('/timeslider')));
$("#returnbutton").attr("href", document.referrer);
</script>
</div>