Comment ajouter onclick php

Fermé
kikzee Messages postés 70 Date d'inscription dimanche 6 mars 2016 Statut Membre Dernière intervention 16 décembre 2020 - 13 mai 2016 à 00:56
kikzee Messages postés 70 Date d'inscription dimanche 6 mars 2016 Statut Membre Dernière intervention 16 décembre 2020 - 13 mai 2016 à 20:00
Bonjour,

comment ajouter
 
onclick="return(confirm('Etes-vous sûr de vouloir supprimer cette entrée'));" >Supprimer>
dans
<a href="./index.php?page=ticket&id='.$_GET['id'].'&action=delete"><img align="right" style="margin:2px 10px 0px 0px; border-style: none;" alt="img" src="./images/delete_max.png" title="Supprimer ce ticket" /></a>';

A voir également:

1 réponse

jordane45 Messages postés 38145 Date d'inscription mercredi 22 octobre 2003 Statut Modérateur Dernière intervention 25 avril 2024 4 650
13 mai 2016 à 09:37
Bonjour,

Comme ça tu veux dire ? :
<a href="./index.php?page=ticket&id='.$_GET['id'].'&action=delete"><img align="right" style="margin:2px 10px 0px 0px; border-style: none;" alt="img" src="./images/delete_max.png" title="Supprimer ce ticket" onclick="return(confirm('Etes-vous sûr de vouloir supprimer cette entrée'));" >Supprimer></a>';


Mais je ne vois pas le rapport avec le php .....
0
kikzee Messages postés 70 Date d'inscription dimanche 6 mars 2016 Statut Membre Dernière intervention 16 décembre 2020 3
13 mai 2016 à 19:59
ça marche pas
0
kikzee Messages postés 70 Date d'inscription dimanche 6 mars 2016 Statut Membre Dernière intervention 16 décembre 2020 3
13 mai 2016 à 20:00
voici le code complet
			if ($rright['ticket_delete']!=0) echo '<a href="./index.php?page=ticket&id='.$_GET['id'].'&action=delete"><img align="right" style="margin:2px 10px 0px 0px; border-style: none;" alt="img" src="./images/delete_max.png" title="Supprimer ce ticket"  /></a>';
0