PAD also runs on PHP compiled to WebAssembly, inside a browser tab, with no PAD server at
all. php wasm/build.php bundles the engine into one file, and the page
wasm/ loads PHP into the tab, writes the engine into its memory
and renders the template you type with the JSON data beside it - the example below, on this
server, is the page's sample:
|
PHP fragments/pad_in_the_browser_1.php |
HTML fragments/pad_in_the_browser_1.pad |
Result |
|---|---|---|
|
|
Fruit
|
@php-wasm packages of WordPress Playground, loaded from
jsDelivr: about 20 MB, once.wasm/README.md says what was verified - the engine on the
PHP 8.3, 8.4 and 8.5 WebAssembly builds, the page in Chrome - and what was not.A whole application runs in the browser the same way, its SQLite database kept there between visits, opened from the disk or installed from an https host: Offline applications.