forked from vergnet/site-accueil-insa
Compare commits
2 commits
2ca75a7bb3
...
9ea0e46285
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9ea0e46285 | ||
|
|
e010316809 |
3 changed files with 4 additions and 27 deletions
10
README.md
10
README.md
|
|
@ -97,16 +97,6 @@ il n'y a globalement pas grand chose à comprendre à part qu'ici la taille (len
|
|||
Tout est modifiable via le panel admin (voir la section "admin" plus bas dans ce readme).
|
||||
|
||||
|
||||
### planning_tmp_dl
|
||||
|
||||
| Nom | Type | AUTO_INCREMENT | NULL |
|
||||
| :----------- |:------------:|:---------------:|:-----:|
|
||||
| planning | text | | |
|
||||
|
||||
permet d'enregistrer l'ics pour le téléchargement voir la section "planning" à propos du script php2ics.
|
||||
|
||||
Par défaut il faut avoir une seule ligne vide, le script se chargera de la modifier à chaque fois.
|
||||
|
||||
### scores
|
||||
|
||||
| Nom | Type | AUTO_INCREMENT | NULL |
|
||||
|
|
|
|||
|
|
@ -143,10 +143,14 @@ if(isset($_POST['download_planning'])) {
|
|||
|
||||
$cal->End();
|
||||
|
||||
<<<<<<< HEAD
|
||||
$cal->DownloadICS("planning_SA_INSA");
|
||||
=======
|
||||
$req = $db->prepare('UPDATE planning_tmp_dl set planning = ?');
|
||||
$req->execute(array($cal->GetICS()));
|
||||
|
||||
header('Location: assets/scripts/planning_tmp.php');
|
||||
>>>>>>> 2ca75a7bb394da5df40132b30b562ab0bdd8552e
|
||||
}
|
||||
|
||||
?>
|
||||
|
|
@ -1,17 +0,0 @@
|
|||
<?php
|
||||
include '../../script/db.php';
|
||||
|
||||
$req = $db->query('SELECT planning FROM planning_tmp_dl');
|
||||
$r = $req -> fetchAll(PDO::FETCH_ASSOC);
|
||||
|
||||
header('Content-Type: text/ics');
|
||||
header('Content-Transfer-Encoding: Binary');
|
||||
header('Content-Disposition:attachment; filename=planning_semaine_accueil.ics');
|
||||
|
||||
echo $r[0]['planning'];
|
||||
|
||||
exit();
|
||||
|
||||
header('Location: ../../index.php');
|
||||
|
||||
?>
|
||||
Loading…
Reference in a new issue