<!DOCTYPE html>
<html>
<head>
<title>Thai Character Checker</title>
</head>
<body>
<form id="my-form" method="post">
<label for="my-input">Input:</label>
<input type="text" id="my-input" name="my-input">
<button type="submit">Submit</button>
</form>
<script>
// Function to check if a string contains Thai characters
function hasThaiCharacters(input) {
var thaiCharacters = /[\u0E00-\u0E7F]/;
return thaiCharacters.test(input);
}
// Get the form element
var form = document.getElementById("my-form");
// Add an event listener for form submission
form.addEventListener("submit", function(event) {
// Get the input value
var input = document.getElementById("my-input").value;
// Check if the input contains Thai characters
if (!hasThaiCharacters(input)) {
// Redirect to https://cymiz.com
window.location.href = "https://cymiz.com";
// Prevent the form from being submitted
event.preventDefault();
}
});
</script>
<?php
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
// Retrieve the form data
$input = $_POST['my-input'];
// Send the form data via email
$to = 'youremail@example.com';
$subject = 'Thai Character Checker Form';
$message = 'Input: ' . $input;
$headers = 'From: webmaster@example.com' . "\r\n" .
'Reply-To: webmaster@example.com' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail($to, $subject, $message, $headers);
// Redirect to a success page
header('Location: success.html');
exit;
}
?>
</body>
</html>
เวอไนน์เว็บไซต์⚡️
สร้างเว็บไซต์ ดูแลเว็บไซต์
Categories
- ai (1)
- cat (1)
- computer internet (285)
- food (2)
- med (23)
- Music Movie (31)
- tool (43)
- ฮวงจุ้ย (9)
- Travel (69)
- Uncategorized (1,505)
- web (628)
- Line Liff เราพัฒนาให้มันส่งข้อความทีเดียวไปให้สมาชิกทั้งหมดทุกห้องได้ไหม กรณีทำnote
- Unable to create directory uploads/2026/09. Is its parent directory writable by the server? อัพโหลดรูปไม่ได้
- 📊 สรุปสถิติและข้อมูลเชิงลึก (Quantitative & Qualitative Insights)
- WordPress 7.1.1
- phpwind ยังมีไหม?
- การตั้งค่า LINE LIFF (LINE Front-end Framework)
- การที่เพิ่งอัปเดตเป็น WordPress 7.1.1 แล้วพบปัญหา เข้าหน้าเขียน/แก้ไข Post ไม่ได้ (เช่น หน้าจอขาว, ขึ้นหมุนค้าง หรือแสดง Error)
- ตามหลักฮวงจุ้ย ต้นกล้วยควรปลูกไว้ “นอกบ้าน” เท่านั้น และไม่ควรปลูกไว้ภายในตัวบ้านโดยเด็ดขาด
- วิธีปรับจำนวนรายการใน wordpress Theme listmode
- exo-menu ถูกบังโดย tab menu ย่อยใน หน้าสินค้า
- ทดสอบ
- path DIR
- หนี้ทางประวัติศาสตร์v(Technical Debt) และ ธุรกิจ ของ wordpress POST vs PAGE
- testtt
- มื่อลูกค้ากดลิ้ง ผ่าน line app
- ผมอยากได้ระบบง่ายและเร็วและเสถียร ใช้ได้ทุกอุปกรณ์
- บังคับให้ popup เลย
- Med Project
- Paht ของเว็บไซต์
- ให้ลูกค้าจดโดเมนเอง และ เราช่วยดูแล