3v4l.org

run code in 300+ PHP versions simultaneously
<?php class TypechoXMLRPC { public $XMLRPC_URL; public $UserName; public $PassWord; public function __constructor($XMLRPC_URL, $UserName, $PassWord) { $this->XMLRPC_URL = $XMLRPC_URL; $this->UserName = $UserName; $this->PassWord = $PassWord; } public function request($requestname, $params) { $request = xmlrpc_encode_request($requestname, $params); $ch = curl_init(); curl_setopt($ch, CURLOPT_POSTFIELDS, $request); curl_setopt($ch, CURLOPT_URL, $this->XMLRPC_URL); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_TIMEOUT, 1); $results = curl_exec($ch); curl_close($ch); return $results; } public function getUsersBlogs() { return $this->request("wp.getUsersBlogs", array($this->UserName, $this->PassWord)); } } $xmlrpc = new TypechoXMLRPC("http://imnerd.org/action/xmlrpc", "admin", "test"); echo $xmlrpc->XMLRPC_URL; $pages = $xmlrpc->getUsersBlogs();
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function xmlrpc_encode_request() in /in/go2tL:15 Stack trace: #0 /in/go2tL(27): TypechoXMLRPC->request('wp.getUsersBlog...', Array) #1 /in/go2tL(32): TypechoXMLRPC->getUsersBlogs() #2 {main} thrown in /in/go2tL on line 15
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:
34.88 ms | 401 KiB | 8 Q