1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-13 18:14:07 +02:00

Permanent link in schema

This commit is contained in:
Jakub Vrana
2010-12-29 18:08:34 +01:00
parent 850d1aa130
commit 61b1fd57e0
4 changed files with 10 additions and 3 deletions

View File

@@ -400,6 +400,9 @@ function schemaMouseup(ev) {
for (var key in tablePos) {
s += '_' + key + ':' + Math.round(tablePos[key][0] * 10000) / 10000 + 'x' + Math.round(tablePos[key][1] * 10000) / 10000;
}
cookie('adminer_schema=' + encodeURIComponent(s.substr(1)), 30, '; path="' + location.pathname + location.search + '"');
s = encodeURIComponent(s.substr(1));
var link = document.getElementById('schema-link');
link.href = link.href.replace(/[^=]+$/, '') + s;
cookie('adminer_schema=' + s, 30, '; path="' + location.pathname + location.search + '"');
}
}