Last active
July 25, 2022 11:39
-
-
Save neno-tech/847813a3faddf8286de2d326946b0c26 to your computer and use it in GitHub Desktop.
โค้ดแสดงผล Sweet Alert เป็นแบบตาราง html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var swal_html = ` | |
<div class="panel" style="background:aliceblue;font-weight:bold"> | |
<div class="panel-body"> | |
<div class="text-center"> | |
<table class="table"> | |
<tbody> | |
<tr> | |
<th scope="row">รหัสนักเรียน :</th> | |
<td>${result[0][0]}</td> | |
</tr> | |
<tr> | |
<th scope="row">ชื่อ สกุล :</th> | |
<td>${result[0][1]}</td> | |
</tr> | |
<tr> | |
<th scope="row">ชื่อเล่น :</th> | |
<td>${result[0][2]}</td> | |
</tr> | |
<tr> | |
<th scope="row">อีเมล :</th> | |
<td>${result[0][3]}</td> | |
</tr> | |
<tr> | |
<th scope="row">ลิ้งค์ :</th> | |
<td><a href ="${result[0][4]}" target="_blank">ดาวน์โหลด</a></td> | |
</tr> | |
</tbody> | |
</table> | |
</div> | |
</div> | |
</div>` | |
Swal.fire({title:"ข้อมูลนักเรียน", html: swal_html}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment