feat(php): Simple web demo
This commit is contained in:
30
ext/php/public/index.php
Normal file
30
ext/php/public/index.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Arboricx Web</title>
|
||||
<script src="https://unpkg.com/htmx.org@2.0.4"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Arboricx Bundle Runner</h1>
|
||||
<form hx-post="eval.php" hx-target="#result" enctype="multipart/form-data">
|
||||
<p>
|
||||
<label>Bundle (.arboricx)<br>
|
||||
<input type="file" name="bundle" accept=".arboricx" required></label>
|
||||
</p>
|
||||
<?php for ($i = 0; $i < 5; $i++): ?>
|
||||
<p>
|
||||
<label>Arg <?= $i + 1 ?> <small>(ignored if empty)</small><br>
|
||||
<input type="text" name="arg<?= $i ?>"></label>
|
||||
</p>
|
||||
<?php endfor; ?>
|
||||
<p>
|
||||
<button type="submit">Run</button>
|
||||
</p>
|
||||
</form>
|
||||
<pre id="result"></pre>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user