|
|
|
จะเรียกใช้งาน SweetAlert2 โดยใช้ echo <script></script> ได้ไ |
|
|
|
|
|
|
|
ผมทำเป็นแบบนี้อะครับ
ลองดู
Code (PHP)
<meta charset="utf8">
<!DOCTYPE html>
<html>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/sweetalert2.all.min.js"></script>
<body onload="myFunction()">
<?php
$id = 1;
if($id == true){
?>
<script>
function myFunction() {
swal({
type: 'error',
title: 'Oops...',
text: 'Something went wrong!',
footer: '<a href>Why do I have this issue?</a>'
})
}
</script>
<?php
}
?>
</body>
</html>
|
|
|
|
|
Date :
2018-12-18 14:29:21 |
By :
nobetaking |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 00
|