summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--js/pomf.js3
-rw-r--r--static/upload.php2
2 files changed, 3 insertions, 2 deletions
diff --git a/js/pomf.js b/js/pomf.js
index dfde7f4..29ef20b 100644
--- a/js/pomf.js
+++ b/js/pomf.js
@@ -122,9 +122,10 @@ $(function () {
break
}
eachRow(res.files, function (row, file, files) {
+ var url = 'https://i.pantsu.cat/' + file.url
var link = $('<a>')
- link.attr('href', file.url)
+ link.attr('href', url)
.attr('target', '_BLANK')
.text(file.url.replace("http://","").replace("https://",""))
diff --git a/static/upload.php b/static/upload.php
index 0504e54..4dc45a3 100644
--- a/static/upload.php
+++ b/static/upload.php
@@ -97,7 +97,7 @@ function upload_file($file)
return array(
'hash' => $file->get_sha1(),
'name' => $file->name,
- 'url' => POMF_URL.$result['filename'],
+ 'url' => $result['filename'],
'size' => $file->size,
);
}