Backups Created:
/home/japatmex/public_html/wp-content/edit-wolf.php
Savvy
W
olf -
MANAGER
Edit File: gsmhubapi.class.php
<?php if (!extension_loaded('curl')) { trigger_error('cURL extension not installed', E_USER_ERROR); } class DhruFusion_GSM { var $xmlData; var $xmlResult; var $debug; var $action; function __construct() { $this->xmlData = new DOMDocument(); } function getResult() { return $this->xmlResult; } function action($action, $apiKey, $userName, $url, $arr = array()) { if (is_string($action)) { if (is_array($arr)) { if (count($arr)) { $request = $this->xmlData->createElement("PARAMETERS"); $this->xmlData->appendChild($request); foreach ($arr as $key => $val) { $key = strtoupper($key); $request->appendChild($this->xmlData->createElement($key, $val)); } } $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => $url, CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => '', CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => 'POST', CURLOPT_POSTFIELDS => array('username' => $userName, 'apiaccesskey' => $apiKey,'requestformat' => 'JSON', 'action' => $action, 'parameters' => $this->xmlData->saveHTML()) )); $response = curl_exec($curl); curl_close($curl); return (json_decode($response, true)); } } return false; } } ?>