Add a config
Ignored intentionally to avoid commting configs.
This commit is contained in:
parent
dfebc3975d
commit
87fbc62214
4 changed files with 5 additions and 3 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -1,3 +1,3 @@
|
|||
i/
|
||||
|
||||
static/js/config.js
|
||||
server
|
||||
|
|
|
@ -181,6 +181,7 @@
|
|||
<script src="/static/js/drop.js"></script>
|
||||
<script src="/static/js/loadencryption.js"></script>
|
||||
<script src="/static/js/downloadable.js"></script>
|
||||
<script src="/static/js/config.js"></script>
|
||||
<script>
|
||||
$(window).unload(function () { $(window).unbind('unload') })
|
||||
</script>
|
||||
|
|
|
@ -68,7 +68,7 @@ $(function () {
|
|||
function downloadfromident(ident) {
|
||||
var xhr = new XMLHttpRequest();
|
||||
xhr.onload = downloaded
|
||||
xhr.open('GET', 'i/' + ident.ident)
|
||||
xhr.open('GET', (g.config.server ? g.config.server : '') + 'i/' + ident.ident)
|
||||
xhr.responseType = 'blob'
|
||||
|
||||
xhr.addEventListener('progress', downloadprogress, false)
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
var g = {}
|
||||
g.config = {}
|
||||
|
||||
$(function () {
|
||||
var pastearea = $('#pastearea')
|
||||
|
@ -19,7 +20,7 @@ $(function () {
|
|||
formdata.append('ident', data.ident)
|
||||
formdata.append('file', data.encrypted)
|
||||
$.ajax({
|
||||
url: 'up',
|
||||
url: (g.config.server ? g.config.server : '') + 'up',
|
||||
data: formdata,
|
||||
cache: false,
|
||||
processData: false,
|
||||
|
|
Loading…
Reference in a new issue