Ich brauche Hilfe, um jConfirm mit diesem vorhandenen Code (php & Jquery & jAlert) zu verwenden.
function logout()
{
if (confirm("Do you really want to logout?"))
window.location.href = "https://stackoverflow.com/questions/1701772/logout.php";
}
Wenn ich nur die Bestätigung in jConfirm ändere, reicht dies nicht aus, damit es funktioniert …
Danke für Ihre Hilfe
Lena
function logout()
{
jConfirm('Do you really want to logout?', 'Logout', function(r) {
if (r)
window.location.href = "https://stackoverflow.com/questions/1701772/logout.php";
});
}
EDIT für Kommentare:
function sid(id){
$_sidId = id;
jConfirm("Delete System ID for " + id + "?", 'Delete Sid', function(r) {
if (r){
window.location.href = "https://stackoverflow.com/questions/1701772/del_sid.php?id=" + $_sidId;
}
$_sidId = null;
});
}
Als ich das Skript besser sah, wäre es wünschenswert, die Variable “$_sidId” aus “if” zu entfernen, unabhängig von der Antwort, es müsste die Variable bereinigen.