okay, first off, new this. instructed use sweet alert alerts in our project. see it work made simple 1 on different file , made code below, it's not working. sweetalert not showing. did miss something?
<!doctype html> <html> <head> <link href="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.css" rel="stylesheet" /> </head> <body> <script> swal("hello world"); </script> <script src="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.js" /> </body> </html>
you calling sweet alert before has been declared , linked html document. move script reference sweetalert.min.js head of page. , also, script tags cannot self closing. need close script tag doing </script>
, this:
<!doctype html> <html> <head> <link href="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.css" rel="stylesheet" /> <script src="https://cdnjs.cloudflare.com/ajax/libs/sweetalert/1.1.3/sweetalert.min.js"></script> </head> <body> <script> swal("hello world"); </script> </body> </html>
Comments
Post a Comment