3v4l.org

run code in 300+ PHP versions simultaneously
<?php $source = <<<EOD <?php include_once "noentry.php"; list(\$get_arr, \$post_arr, \$request_arr) = get_secure_request_params(); \$mode = empty(\$get_arr['mode']) ? 'add' : \$get_arr['mode']; try { if (!in_array(strtolower(\$mode), ['add', 'update'])) { throw new Exception("Error Processing Request", 0); } \$msg = trim(\$get_arr['var_msg']); if (strtolower(\$mode) == 'update') { \$top_header="Update ".'$module_header'; \$id = \$get_arr['$table_primary_key']; \$db_data = \$mfa_db_obj->db->table('$table_name')->select('*')->where('$table_primary_key', \$id)->first(); if(empty(\$db_data)) { \$redirect_url=\$admin_url."index.php?file=sitemap&AX=No"; header("Location:".\$redirect_url); } } } catch (Exception \$e) { \$exception_message=\$e->getMessage(); \$redirect_url=\$admin_url . "{$listing_url}&var_msg=".\$exception_message; header("Location:".\$redirect_url); exit; } include_once "common_css.php"; include_once "common_js.php"; ?> EOD; $tokens = token_get_all($source); foreach ($tokens as $token) { list($id, $text) = $this->get_token($token); $lower_text = strtolower($text); if (T_STRING == $id && isset($alias_list[$lower_text])) { $alias_count[$lower_text] ++; } $return .= $text; } function get_token($token) { if (is_string($token)) { return array($token, $token); } else { return $token; } } echo $return;
Output for git.master, git.master_jit, rfc.property-hooks
Warning: Undefined variable $module_header in /in/OaBg4 on line 14 Warning: Undefined variable $table_primary_key in /in/OaBg4 on line 15 Warning: Undefined variable $table_name in /in/OaBg4 on line 16 Warning: Undefined variable $table_primary_key in /in/OaBg4 on line 16 Warning: Undefined variable $listing_url in /in/OaBg4 on line 25 Fatal error: Uncaught Error: Using $this when not in object context in /in/OaBg4:35 Stack trace: #0 {main} thrown in /in/OaBg4 on line 35
Process exited with code 255.

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:
74.25 ms | 401 KiB | 8 Q