3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Define the PHP value in your code $js_user_acc = true; ?> <html> <head> <title>whatever</title> <!-- in the HTML output, set it as a Javascript literal value --> <script> var MyNamespace = { user_acc: <?= json_encode($js_user_acc) ?>, }; </script> </head> <body> <div>foo</div> </body> </html>
Output for git.master_jit, git.master, rfc.property-hooks
<html> <head> <title>whatever</title> <!-- in the HTML output, set it as a Javascript literal value --> <script> var MyNamespace = { user_acc: true, }; </script> </head> <body> <div>foo</div> </body> </html>

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
42.8 ms | 1611 KiB | 4 Q