2024-05-10 09:36:05 +00:00
|
|
|
<?php
|
|
|
|
if ($_SERVER['REQUEST_METHOD'] === 'POST') var_dump($_POST);
|
2024-05-10 09:34:47 +00:00
|
|
|
|
2024-05-10 09:36:05 +00:00
|
|
|
echo <<<HTML
|
|
|
|
<button onclick="sendPostWithData('test.php', {name: 'John', surname: 'Doe'})">Send</button>
|
|
|
|
<script src="script.js"></script>
|
|
|
|
HTML;
|