3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<form method="post"> <div class=control-group> <label class=control-label for=input>User ID</label> <div class=controls> <input id=input name=fbid class=input-xlarge type=text placeholder="User ID"> </div> <label class=control-label for=input>Cash</label> <div class=controls> <input id=input name=gems class=input-xlarge type=text placeholder="Cash"> </div> <label class=control-label for=input>Gold</label> <div class=controls> <input id=input name=gold class=input-xlarge type=text placeholder="Gold"> </div> <label class=control-label for=input>Exp</label> <div class=controls> <input id=input name=xp class=input-xlarge type=text placeholder="Exp"> </div> <label class=control-label for=input>Level</label> <div class=controls> <input id=input name=level class=input-xlarge type=text placeholder="level"> </div> <div class=form-actions> <input class="btn btn-wuxia btn-large btn-primary" type=submit name="kirim" value="Submit" /></input> </div> </a> </form> <?php if(isset($_POST['kirim'])){ $jumlah_gem=$_POST['gems']; $jumlah_gold=$_POST['gold']; $jumlah_xp=$_POST['xp']; $jumlah_level=$_POST['level']; $result=sendPost("http://dynamic.socialpoint.**/appsfb/socialpark/srv/get_player_info.php?USERID=".$_POST['fbid'],null); $data = json_decode($result,true); $str=''; //$str=$payload[1].'<br/>'; $str .= "<br/>=============================<br/>"; $str .= "Name : ".$data['playerInfo']['name']."<br/>"; $str .= "Gems : ".number_format($data['playerInfo']['cash'],0,',','.')."<br/>"; $str .= "Gold : ".number_format($data['playerInfo']['coins'],0,',','.')."<br/>"; $str .= "XP : ".number_format($data['playerInfo']['xp'],0,',','.')."<br/>"; $str .= "Level : ".number_format($data['playerInfo']['level'],0,',','.')."<br/>"; $cmd[]=array('cmd'=>'set_variables','args'=>array($data['playerInfo']['coins']+$jumlah_gold,$data['playerInfo']['cash']+$jumlah_gem,$data['playerInfo']['xp']+$jumlah_xp,$jumlah_level)); $res=sendCommand($_POST['fbid'],$cmd); //if($res){ $result=sendPost("http://dynamic.socialpoint.**/appsfb/socialpark/srv/get_player_info.php?USERID=".$_POST['fbid'],null); $data = json_decode($result,true); $str .= "<br/>=============================<br/>"; $str .= "Name: ".$data['playerInfo']['name']."<br/>"; $str .= "Gems: ".number_format($data['playerInfo']['cash'],0,',','.')."<br/>"; $str .= "Gold: ".number_format($data['playerInfo']['coins'],0,',','.')."<br/>"; $str .= "Exp: ".number_format($data['playerInfo']['xp'],0,',','.')."<br/>"; $str .= "Level: ".number_format($data['playerInfo']['level'],0,',','.')."<br/>"; $str .= "=============================<br/>"; //} echo $str; } function sendPost($url,$data=null){ if($data!=null){ $postdata=http_build_query($data); $opts = array('http' => array( 'method' => 'POST', 'timeout' => 30, 'header' => "Content-type: application/x-www-form-urlencoded\r\n"."Content-Length: ".strlen($postdata)."\r\n", 'content' => $postdata ) ); }else $opts = array('http'=>array('timeout'=>30)); $result=file_get_contents($url,false,stream_contex t_create($opts)); return $result; } function sendCommand($fbid,$cmd){ $cmd = json_encode(array('commands'=>$cmd,'tries'=>1,'fir st_number'=>1)); $cmd=array('data'=>$cmd); $result=sendPost("http://dynamic.socialpoint.**/appsfb/socialpark/srv/command.php?USERID=".$fbid,$cmd); $result = json_decode($result,true); return $result; } ?> Veja mais: http://www.cheatsbrasil.org/local/facebook-e-orkut-games/178118-script-dragon-city-social-warrs-social-empires-dark-warriors-social-park.html#ixzz36X6Vetss
Output for 5.4.0 - 5.6.8
Parse error: syntax error, unexpected end of file in /in/egEeV on line 3
Process exited with code 255.
Output for 5.3.0 - 5.3.29
Parse error: syntax error, unexpected $end in /in/egEeV on line 3
Process exited with code 255.