mirror of
https://github.com/neocities/neocities.git
synced 2025-04-25 09:42:36 +02:00
switch to ajax call to disable mystery caching that's popped up for some reason
This commit is contained in:
parent
28ed2718ba
commit
5a77fcb519
1 changed files with 36 additions and 31 deletions
|
@ -163,8 +163,12 @@
|
||||||
|
|
||||||
var editor = {}
|
var editor = {}
|
||||||
|
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$.get("/site_files/download/<%= Addressable::URI.parse(@filename).normalized_path.to_s %>", function(resp) {
|
$.ajax({
|
||||||
|
url: "/site_files/download/<%= Addressable::URI.parse(@filename).normalized_path.to_s %>",
|
||||||
|
cache: false,
|
||||||
|
success: function(resp) {
|
||||||
editor = ace.edit("editor")
|
editor = ace.edit("editor")
|
||||||
setTheme()
|
setTheme()
|
||||||
<% if @ace_mode %>
|
<% if @ace_mode %>
|
||||||
|
@ -197,8 +201,9 @@
|
||||||
saveTextFile(false)
|
saveTextFile(false)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
}
|
||||||
})
|
});
|
||||||
|
});
|
||||||
|
|
||||||
window.onbeforeunload = function() {
|
window.onbeforeunload = function() {
|
||||||
if(unsavedChanges == true)
|
if(unsavedChanges == true)
|
||||||
|
|
Loading…
Add table
Reference in a new issue