summaryrefslogtreecommitdiff
path: root/view
diff options
context:
space:
mode:
authorpolo <ordipolo@gmx.fr>2023-04-23 23:39:10 +0200
committerpolo <ordipolo@gmx.fr>2023-04-23 23:39:10 +0200
commit21746f17dbd12499f794b1f2822b50e9e6c5d494 (patch)
treea8769620928d112bc5f4752b87886d5d2f2c90ea /view
parent6d4de815d7252956c4507b8767bd4b79b9a71fc8 (diff)
downloadmelaine-21746f17dbd12499f794b1f2822b50e9e6c5d494.zip
bouton partager
Diffstat (limited to 'view')
-rw-r--r--view/album.php15
-rw-r--r--view/articlesContent.php13
-rw-r--r--view/courriel.php2
-rw-r--r--view/discographie.php13
-rw-r--r--view/template-formulaires.php1
5 files changed, 28 insertions, 16 deletions
diff --git a/view/album.php b/view/album.php
index e2989dc..f0fd807 100644
--- a/view/album.php
+++ b/view/album.php
@@ -88,23 +88,20 @@ else
88// modifier ouvre l'éditeur, supprimer renvoie vers la discographie 88// modifier ouvre l'éditeur, supprimer renvoie vers la discographie
89if($_SESSION['admin'] == 1 && (!isset($_GET['action']) || $_GET['action'] !== 'edition')) 89if($_SESSION['admin'] == 1 && (!isset($_GET['action']) || $_GET['action'] !== 'edition'))
90{ 90{
91 $lien_partage = 'index.php?page=' . $page . '&file_code=' . $fileCode;
92 global $host;
91?> 93?>
92 <p> 94 <p>
95 <a href="<?= $lien_partage ?>" >
96 <img src="public/icone_partager.png" onclick="copierDansPressePapier('<?= $host ?>/<?= $lien_partage ?>')" >
97 </a>
93 <a href="index.php?page=album&action=edition&file_code=<?= $fileCode ?>" > 98 <a href="index.php?page=album&action=edition&file_code=<?= $fileCode ?>" >
94 <img src="public/icone_modifier.png" > 99 <img src="public/icone_modifier.png" >
95 </a> 100 </a>
96 <a href="index.php?page=discographie&action=suppression&file_code=<?= $fileCode ?>" onclick="confirmerSuppression()" > 101 <a href="index.php?page=discographie&action=suppression&file_code=<?= $fileCode ?>" onclick="confirmerSuppression()" >
97 <img src="public/icone_supprimer.png" > 102 <img src="public/icone_supprimer.png" >
98 </a> 103 </a>
99 <a class="linkAlbumHTML" href="index.php?page=discographie" >Retour à la discographie</a> 104 <button><a href="index.php?page=discographie" >Retour page discographie</a></button>
100 </p>
101<?php
102}
103else
104{
105?>
106 <p>
107 <a class="linkAlbumHTML" href="index.php?page=discographie" >Retour à la discographie</a>
108 </p> 105 </p>
109<?php 106<?php
110} 107}
diff --git a/view/articlesContent.php b/view/articlesContent.php
index c07ba75..4762f8e 100644
--- a/view/articlesContent.php
+++ b/view/articlesContent.php
@@ -22,9 +22,11 @@ if($_SESSION['admin'] == 1)
22?> 22?>
23 <div> 23 <div>
24 <p class="boutonArticle boutonNouvelArticle" > 24 <p class="boutonArticle boutonNouvelArticle" >
25 <a href="index.php?page=<?= $page ?>&action=editor" > 25 <button>
26 <span>Nouvel article</span> 26 <a href="index.php?page=<?= $page ?>&action=editor" >
27 </a> 27 Nouvel article
28 </a>
29 </button>
28 </p> 30 </p>
29<?php 31<?php
30 } 32 }
@@ -81,9 +83,14 @@ for($i = 0; $i < $Articles->fileListCount; $i++)
81 // bouton 83 // bouton
82 if($_SESSION['admin'] == 1) 84 if($_SESSION['admin'] == 1)
83 { 85 {
86 $lien_partage = 'index.php?page=' . $page . '#' . $Articles->fileList[$i]['fileCode'];
87 global $host;
84 ?> 88 ?>
85 </div> 89 </div>
86 <p class="boutonArticle" > 90 <p class="boutonArticle" >
91 <a href="<?= $lien_partage ?>" >
92 <img src="public/icone_partager.png" onclick="copierDansPressePapier('<?= $host ?>/<?= $lien_partage ?>')" >
93 </a>
87 <a href="index.php?page=<?= $page ?>&action=editor&file_code=<?= $Articles->fileList[$i]['fileCode'] ?>#<?= $Articles->fileList[$i]['fileCode'] ?>" > 94 <a href="index.php?page=<?= $page ?>&action=editor&file_code=<?= $Articles->fileList[$i]['fileCode'] ?>#<?= $Articles->fileList[$i]['fileCode'] ?>" >
88 <img src="public/icone_modifier.png" ></a> 95 <img src="public/icone_modifier.png" ></a>
89 <a href="index.php?page=<?= $page ?>&action=monter&file_code=<?= $Articles->fileList[$i]['fileCode'] ?>&position=<?= $Articles->fileList[$i]['position'] ?>#<?= $Articles->fileList[$i]['fileCode'] ?>" > 96 <a href="index.php?page=<?= $page ?>&action=monter&file_code=<?= $Articles->fileList[$i]['fileCode'] ?>&position=<?= $Articles->fileList[$i]['position'] ?>#<?= $Articles->fileList[$i]['fileCode'] ?>" >
diff --git a/view/courriel.php b/view/courriel.php
index 7dd7ba4..8934461 100644
--- a/view/courriel.php
+++ b/view/courriel.php
@@ -6,6 +6,6 @@
6 6
7 <div id="courrielJS" > 7 <div id="courrielJS" >
8 <button onclick="clientCourriel();" >Avec mon logiciel<br />de messagerie</button> 8 <button onclick="clientCourriel();" >Avec mon logiciel<br />de messagerie</button>
9 <button onclick="copierAdresse();" >Copier l'adresse dans<br />le presse-papier</button> 9 <button onclick="copierCourriel();" >Copier l'adresse dans<br />le presse-papier</button>
10 </div> 10 </div>
11 </div> \ No newline at end of file 11 </div> \ No newline at end of file
diff --git a/view/discographie.php b/view/discographie.php
index 206a9b8..c5c9135 100644
--- a/view/discographie.php
+++ b/view/discographie.php
@@ -84,9 +84,11 @@ if($_SESSION['admin'] == 1)
84 <!-- le bouton Nouvel album est considéré comme un article --> 84 <!-- le bouton Nouvel album est considéré comme un article -->
85 <article> 85 <article>
86 <p class="boutonAlbum" > 86 <p class="boutonAlbum" >
87 <a href="index.php?page=discographie&action=edition" > 87 <button>
88 <span>Nouvel album</span> 88 <a href="index.php?page=discographie&action=edition" >
89 </a> 89 Nouvel album
90 </a>
91 </button>
90 </p> 92 </p>
91 </article> 93 </article>
92<?php 94<?php
@@ -147,8 +149,13 @@ for($i = 0; $i < $Albums->fileListCount; $i++)
147 // boutons 149 // boutons
148 if($_SESSION['admin'] == 1) 150 if($_SESSION['admin'] == 1)
149 { 151 {
152 /*$lien_partage = 'index.php?page=' . $page . '#' . $Albums->fileList[$i]['fileCode'];
153 global $host;*/
150 ?> 154 ?>
151 <p> 155 <p>
156 <!-- <a href="<?= $lien_partage ?>" >
157 <img src="public/icone_partager.png" onclick="copierDansPressePapier('<?= $host ?>/<?= $lien_partage ?>')" >
158 </a> -->
152 <a href="index.php?<?= $lienBoutonModif[$i] ?>" > 159 <a href="index.php?<?= $lienBoutonModif[$i] ?>" >
153 <img src="public/icone_modifier.png" > 160 <img src="public/icone_modifier.png" >
154 </a> 161 </a>
diff --git a/view/template-formulaires.php b/view/template-formulaires.php
index be51df6..e7c7470 100644
--- a/view/template-formulaires.php
+++ b/view/template-formulaires.php
@@ -56,6 +56,7 @@ if($page === 'discographie' || $page === 'album')
56 <a class="boutonAnnuler" href="index.php?page=<?= $lienBoutonAnnuler ?>" > 56 <a class="boutonAnnuler" href="index.php?page=<?= $lienBoutonAnnuler ?>" >
57 <input type="button" value="Annuler" /> 57 <input type="button" value="Annuler" />
58 </a> 58 </a>
59 <button><a href="index.php?page=discographie" >Retour page discographie</a></button>
59 60
60 <script> 61 <script>
61 let editor; // variable utilisable depuis une fonction 62 let editor; // variable utilisable depuis une fonction