I use Sweet Alert 2 for nice dialogs. Now I want to use it for a security question if an database entry should be delete or not. It’s no problem to show the dialog, but I can’t find a way to integrate a function if the delete is confimred. Could anyone please help me? Thats the code for now: Answer
Tag: sweetalert
sweetalert not working in php after form submission
i have a simple php form, on form submit i want to display sweet alert, i did the following code: howerver sweetalert doesnt show up after formsubmit, can anyone please tell me what is wrong in here, thanks in advance Answer Because your body is empty and sweetalert append your code to empty body & you got error in your
Redirect to a web page when a user clicks on the ok button of the sweet alert
I am using sweet alert (https://sweetalert2.github.io/) to pop up a success alert after a registration in this way: But I don’t know why if I use this other way the sweet alert doesn’t work: I want that if a user clicks on ok, he will be redirected to another web page, but I don’t know how to do it but
Fetch Data from express server via sweetalert
Hey i made an webserver with nodejs and express if i sent a request to ip/test it give me text via res.send(‘test) i want to fetch this text via sweetalert but it always fail :/ The JavaScript Code: And the Nodejs Express Code: Answer i found the answer:
SweetAlert2 disallow outside click after confirm
I want to create an alert similar to the ajax-example, but allowing outside click dismiss before confirming. After the user clicks confirm I would like to disallow outside click until the operation is finished. Setting the config variable allowOutsideClick to false like in the example will never allow outside click and I don’t see a valid method in the docs
Sweetalert2 redirection
I’m struggling with this for a few hours already and I think that the solution is very simple. First a bit of background. So, I have a php page where I can enter a number in a texfield. If the number entered is higher than the credit the user has, then I have to show an error message. When the
SweetAlert showLoaderOnConfirm not displaying
i am using sweetalert to display delete confirmation,and process it later while displayin a loading action,though it is not working,thi is the code,that doesn’t work (it is supposed to display a loading animation,but it actually is not doing so) any thoughts ? This the javascript Html this is the fiddle Answer I assume your include files are wrong (old for
How to redirect page after click on Ok button on sweet alert?
I am able to display sweet alert after the page refresh but I have to click on Ok button which I am getting on sweet alert to redirect the page.Please help me in this. Answer To specify a callback function, you have to use an object as the first argument, and the callback function as the second argument.
SweetAlert prompt with two input fields
Currently working on a personal project. I want the user to click a button and a SweetAlert prompt would be presented for the user to verify their credential. However, the code I see on the SweetAlert website only allows one input field. Here is the code I have: So, is there a way I can get two input fields? One