3v4l.org

run code in 300+ PHP versions simultaneously
<?php function go_replace_get($tip,$id1="",$id2="",$id3="",$id4="",$id5="") { global $ayar; $tip = 'aktif_'.$tip.'_redirect'; $url = $ayar[$tip]; $url = preg_replace('@{id1}@si',$id1,$url); $url = preg_replace('@{id2}@si',$id2,$url); $url = preg_replace('@{id3}@si',$id3,$url); $url = preg_replace('@{id4}@si',$id4,$url); $url = preg_replace('@{id5}@si',$id5,$url); return $url; } function go_replace($tip,$id1="",$id2="",$id3="",$id4="",$id5="") { global $ayar; $tip = 'aktif_'.$tip.'_redirect'; $url = $ayar[$tip]; $url = preg_replace('@{id1}@si',$id1,$url); $url = preg_replace('@{id2}@si',$id2,$url); $url = preg_replace('@{id3}@si',$id3,$url); $url = preg_replace('@{id4}@si',$id4,$url); $url = preg_replace('@{id5}@si',$id5,$url); go_redirect($url); } function go_redirect ($url, $time = 0){ if ($time) header("Refresh: {$time}; url={$url}"); else header("Location: {$url}"); } echo go_replace_get("okru",'34135411244',"","");
Output for 8.3.0 - 8.3.7
Warning: Trying to access array offset on null in /in/hfpjd on line 6 Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /in/hfpjd on line 7
Output for 8.1.0 - 8.1.28, 8.2.0 - 8.2.19
Warning: Trying to access array offset on value of type null in /in/hfpjd on line 6 Deprecated: preg_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /in/hfpjd on line 7
Output for 8.0.0 - 8.0.30
Warning: Trying to access array offset on value of type null in /in/hfpjd on line 6
Output for 7.4.0 - 7.4.33
Notice: Trying to access array offset on value of type null in /in/hfpjd on line 6
Output for 5.4.0 - 5.4.45, 5.5.24 - 5.5.35, 5.6.7 - 5.6.28, 7.0.0 - 7.0.20, 7.1.0 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.33

preferences:
191.11 ms | 403 KiB | 258 Q