This file contains hidden or 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
<?php | |
header('Content-Type: application/json'); | |
$input = json_decode(file_get_contents('php://input'), true); | |
if (!isset($input['message']) || empty(trim($input['message']))) { | |
http_response_code(400); | |
echo json_encode(['error' => 'No message provided']); | |
exit; | |
} |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Live chatku</title> | |
<meta charset="UTF-8"> | |
<style> | |
#hasil { | |
margin-top: 10px; | |
padding: 10px; | |
border: 1px solid #ccc; |
This file contains hidden or 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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Binding dua arah</title> | |
<script src="https://cdn.jsdelivr.net/npm/vue"></script> | |
</head> | |
<body> |
This file contains hidden or 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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Binding satu arah</title> | |
<script src="https://cdn.jsdelivr.net/npm/vue"></script> | |
</head> | |
<body> |
This file contains hidden or 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
<div> | |
<section class="relative py-6 bg-white bg-gray-200 min-w-screen animation-fade animation-delay"> | |
<div class="container h-full max-w-5xl mx-auto overflow-hidden rounded-lg shadow"> | |
@if ($success) | |
<div class="inline-flex w-full ml-3 overflow-hidden bg-white rounded-lg shadow-sm"> | |
<div class="flex items-center justify-center w-12 bg-green-500"> | |
</div> | |
<div class="px-3 py-2 text-left"> | |
<span class="font-semibold text-green-500">Berhasil</span> | |
<p class="mb-1 text-sm leading-none text-gray-500">{{ $success }}</p> |