diff options
Diffstat (limited to 'public/inversion.js')
-rw-r--r-- | public/inversion.js | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/public/inversion.js b/public/inversion.js new file mode 100644 index 0000000..20a6871 --- /dev/null +++ b/public/inversion.js | |||
@@ -0,0 +1,16 @@ | |||
1 | // public/inversion.js | ||
2 | |||
3 | // inverser la position de deux "articles" ou albums d'une page | ||
4 | function inversion() | ||
5 | { | ||
6 | var page = ''; | ||
7 | var action = ''; // monter ou descendre | ||
8 | var fileCode = ''; // <?= $Articles->fileList[$i]['fileCode'] ?> | ||
9 | var position = ''; // <?= $Articles->fileList[$i]['position'] ?> | ||
10 | |||
11 | const xhr = new XMLHttpRequest(); | ||
12 | url = 'index.php?page='+page+'&action='+action+'&file_code='+fileCode+'&position='+position+'#'+fileCode; | ||
13 | url = 'index.php?action=restauration&file_name='+fileInfos.name+'&file_size='+fileInfos.size; | ||
14 | xhr.open("GET", url); | ||
15 | xhr.send(); | ||
16 | } \ No newline at end of file | ||