function run_transaction($vars, $method = 'threeDSecureEnrolmentRequest')
 {
     $client = new soapclient($u = 'https://www.secpay.com/java-bin/services/SECCardService?wsdl', true);
     $err = $client->getError();
     if ($err) {
         return array('message' => sprintf(_PLUG_PAY_SECPAY_ERROR, $err));
     }
     $result = $client->call($method, $vars, "http://www.secpay.com");
     // Check for a fault
     if ($client->fault) {
         if ($err) {
             return array('message' => _PLUG_PAY_SECPAY_ERROR2 . join(' - ', array_values($result)));
         }
     } else {
         // Check for errors
         $err = $client->getError();
         if ($err) {
             return array('message' => sprintf(_PLUG_PAY_SECPAY_ERROR3, $err));
         } else {
             if ($result[0] == '?') {
                 $result = substr($result, 1);
             }
             $ret = $this->reparse($result);
             return $ret;
         }
     }
 }
Exemple #2
0
function Mist($p)
{
    $client = new soapclient(WSDL, array('typemap' => array(array("type_ns" => "uri:mist", "type_name" => "A"))));
    try {
        $client->Mist(array("XX" => "xx"));
    } catch (SoapFault $x) {
    }
    return array("A" => "ABC", "B" => "sss");
}
Exemple #3
0
function create_soap_client()
{
    $client = new soapclient('http://siap.ufcspa.edu.br/siap_ws.php?wsdl', true);
    $err = $client->getError();
    if ($err) {
        // Display the error
        echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
        // At this point, you know the call that follows will fail
    }
    return $client;
}
 public function PinPaymentEnquiry($authorityCode, $status)
 {
     // instantiate the SOAP client object
     $soap = new soapclient($this->wsdl, "wsdl");
     // get the SOAP proxy object, which allows you to call the methods directly
     $proxy = $soap->getProxy();
     // set parameter parameters (PinPaymentEnquiry^)
     $parameters = array(pin => $this->pin, authority => $authorityCode, status => $status);
     // get the result, a native PHP type, such as an array or string
     $result = $proxy->PinPaymentEnquiry($parameters);
     return $result;
 }
 public function Connect()
 {
     // instantiate wsdl cache manager
     if ($this->mDbConfig['db_wsdl_cache_path'] != '' && $this->mDbConfig['db_wsdl_cache_enabled']) {
         $wsdl_cache = new wsdlcache($this->mDbConfig['db_wsdl_cache_path'], $this->mDbConfig['db_wsdl_cache_lifetime']);
     }
     // try to get from cache first...
     $wsdl_url = $this->mDbConfig['db_wsdl_url'];
     if ($this->mDbConfig['db_namespace']) {
         $wsdl_url_query = parse_url($wsdl_url, PHP_URL_QUERY);
         if (!$wsdl_url_query) {
             $wsdl_url .= '?nspace=' . $this->mDbConfig['db_namespace'];
         } else {
             $wsdl_url .= '&nspace=' . $this->mDbConfig['db_namespace'];
         }
     }
     if ($wsdl_cache) {
         $wsdl = $wsdl_cache->get($wsdl_url);
     }
     // cache hit? if not, get it from server and put to cache
     if (!$wsdl) {
         SysLog::Log('Cache MISSED: ' . $wsdl_url, 'SoapDatabaseEngine');
         $wsdl = new wsdl($wsdl_url, $this->mDbConfig['db_proxy_host'], $this->mDbConfig['db_proxy_port'], $this->mDbConfig['db_proxy_user'], $this->mDbConfig['db_proxy_pass'], $this->mDbConfig['db_connection_timeout'], $this->mDbConfig['db_response_timeout']);
         $this->mErrorMessage = $wsdl->getError();
         if ($this->mErrorMessage) {
             SysLog::Log('WSDL error: ' . $this->mErrorMessage, 'DatabaseEngine');
             $this->mErrorMessage = 'An error has occured when instantiating WSDL object (' . $this->mDbConfig['db_wsdl_url'] . '&nspace=' . $this->mDbConfig['db_namespace'] . '). The error was: "' . $this->mErrorMessage . '" Check your WSDL document or database configuration.';
             return FALSE;
         }
         if ($wsdl_cache) {
             $wsdl_cache->put($wsdl);
         }
     } else {
         SysLog::Log('Cache HIT: ' . $this->mDbConfig['db_wsdl_url'] . '&nspace=' . $this->mDbConfig['db_namespace'], 'SoapDatabaseEngine');
     }
     // use it as usual
     $temp = new soapclient($wsdl, TRUE, $this->mDbConfig['db_proxy_host'], $this->mDbConfig['db_proxy_port'], $this->mDbConfig['db_proxy_user'], $this->mDbConfig['db_proxy_pass'], $this->mDbConfig['db_connection_timeout'], $this->mDbConfig['db_response_timeout']);
     $this->mErrorMessage = $temp->getError();
     if (!$this->mErrorMessage) {
         $this->mrDbConnection = $temp->getProxy();
         if (isset($this->mDbConfig['db_credentials'])) {
             $this->mrDbConnection->setCredentials($this->mDbConfig['db_credentials']['user'], $this->mDbConfig['db_credentials']['pass'], $this->mDbConfig['db_credentials']['type'], $this->mDbConfig['db_credentials']['cert']);
         }
         return TRUE;
     } else {
         SysLog::Log('Error in SoapDatabaseEngine: ' . $temp->getError(), 'SoapDatabaseEngine');
         return FALSE;
     }
 }
 function PinPaymentEnquiry($_authority)
 {
     $soapclient = new soapclient('https://pec.shaparak.ir/pecpaymentgateway/eshopservice.asmx?wsdl', 'wsdl');
     if (!$soapclient or $err = $soapclient->getError()) {
         echo $err . "<br />";
         return FALSE;
     } else {
         $status = $_status;
         $params = array('pin' => $this->pin, 'status' => $status, 'authority' => $_authority);
         // to see if we can change it
         $sendParams = array($params);
         $res = $soapclient->call('PinPaymentEnquiry', $sendParams);
         $status = $res['status'];
         return $status;
     }
 }
 public function invoke($targetObject, $function, $arguments)
 {
     $proxyhost = '';
     $proxyport = '';
     $proxyusername = '';
     $proxypassword = '';
     $client = new soapclient($targetObject, true, $proxyhost, $proxyport, $proxyusername, $proxypassword);
     $err = $client->getError();
     if ($err) {
         throw new Exception($err);
     }
     $args = array();
     foreach ($arguments as $argument) {
         if ($argument instanceof IAdaptingType) {
             $args[] = $argument->defaultAdapt();
         } else {
             $args[] = $argument;
         }
     }
     $serviceDesription;
     //			if(isset($_SESSION['wsdl'][$targetObject][$function]))
     //			{
     //				$serviceDesription = unserialize($_SESSION['wsdl'][$targetObject][$function]);
     //				var_dump($serviceDesription);
     //			}
     //			else
     //			{
     $webInsp = new WebServiceInspector();
     $webInsp->inspect($targetObject, $function);
     $serviceDesription = $webInsp->serviceDescriptor;
     $_SESSION['wsdl'][$targetObject][$function] = serialize($serviceDesription);
     //			}
     $methods = $serviceDesription->getMethods();
     $method = null;
     foreach ($methods as $method) {
         if ($method->getName() == $function) {
             break;
         }
     }
     $postdata = array(array());
     foreach ($method->getArguments() as $argument) {
         $this->getArrayArguments($postdata[0], $argument->getType(), $args);
     }
     $result = $client->call($function, $postdata);
     return new Value($result);
 }
 function process_thanks(&$vars)
 {
     global $db;
     require_once 'lib/nusoap.php';
     if ($vars['result'] != 'success') {
         return "Payment failed.";
     }
     $client = new soapclient('http://wsdl.eu.clickandbuy.com/TMI/1.4/TransactionManagerbinding.wsdl', true);
     $err = $client->getError();
     if ($err) {
         return "Error: " . $err;
     }
     $payment_id = intval($vars['payment_id']);
     $pm = $db->get_payment($payment_id);
     $product =& get_product($pm['product_id']);
     if ($product->config['is_recurring']) {
         ////// set expire date to infinite
         ////// admin must cancel it manually!
         $p['expire_date'] = '2012-12-31';
         $db->update_payment($payment_id, $p);
     }
     if ($this->config['disable_second_confirmation']) {
         $err = $db->finish_waiting_payment($pm['payment_id'], 'clickandbuy', $pm['data']['trans_id'], '', $vars);
         if ($err) {
             return "Error: " . $err;
         }
     } else {
         $secondconfirmation = array('sellerID' => $this->config['seller_id'], 'tmPassword' => $this->config['tm_password'], 'slaveMerchantID' => '0', 'externalBDRID' => $pm['data']['ext_bdr_id']);
         /*Start Soap Request*/
         $result = $client->call('isExternalBDRIDCommitted', $secondconfirmation, 'https://clickandbuy.com/TransactionManager/', 'https://clickandbuy.com/TransactionManager/');
         if ($client->fault) {
             return "Soap Request Fault [" . $client->getError() . "]";
         } else {
             $err = $client->getError();
             if ($err) {
                 return "Error " . $err;
             } else {
                 $err = $db->finish_waiting_payment($pm['payment_id'], 'clickandbuy', $pm['data']['trans_id'], '', $vars);
                 if ($err) {
                     return "Error " . $err;
                 }
             }
         }
     }
 }
Exemple #9
0
 private function paynow_check($params)
 {
     $soap = "https://www.paysbuy.com/api_paynow/api_paynow.asmx?WSDL";
     $method = 'api_paynow_authentication_new';
     $merchant = $this->pay_model->get_merchant_data_by_pay_type($params['pay_type'], $params['method_id']);
     $psbID = $merchant['merchant_key'];
     $username = $merchant['merchant_name'];
     $secureCode = $merchant['merchant_key2'];
     // var_dump($psbID);var_dump($username);var_dump($secureCode);die();
     $soap_param = array(array('psbID' => $psbID, 'username' => $username, 'secureCode' => $secureCode, 'inv' => $params['order_sn'], 'itm' => 'Buy Gold', 'amt' => $params['pay_amount'], 'paypal_amt' => 1, 'curr_type' => 'TH', 'com' => '', 'method' => 5, 'language' => 'T', 'resp_front_url' => base_url() . 'paysbuy/return_status', 'resp_back_url' => base_url() . 'paysbuy/return_status', 'opt_fix_redirect' => '1', 'opt_fix_method' => '', 'opt_name' => '', 'opt_email' => '', 'opt_mobile' => '', 'opt_address' => '', 'opt_detial' => ''));
     $client = new soapclient($soap);
     $client->soap_defencoding = 'UTF-8';
     $client->decode_utf8 = false;
     $result = $client->__call($method, $soap_param);
     $string = $result->api_paynow_authentication_newResult;
     //	var_dump($string);
     return $string;
 }
Exemple #10
0
/**
 * The nuSoap client implementation
 * 
 * @return mixed The web service results
 */
function webServiceAction_nusoap(&$amfbody, $webServiceURI, $webServiceMethod, $args, $phpInternalEncoding)
{
    $installed = @(include_once AMFPHP_BASE . "lib/nusoap.php");
    if ($installed) {
        $soapclient = new soapclient($webServiceURI, 'wsdl');
        // create a instance of the SOAP client object
        $soapclient->soap_defencoding = $phpInternalEncoding;
        if (count($args) == 1 && is_array($args)) {
            $result = $soapclient->call($webServiceMethod, $args[0]);
            // execute without the proxy
        } else {
            $proxy = $soapclient->getProxy();
            //
            $result = call_user_func_array(array($proxy, $webServiceMethod), $args);
        }
        //echo $soapclient->getDebug();
        return $result;
    } else {
        trigger_error("nuSOAP is not installed correctly, it should be in lib/nusoap.php", E_USER_ERROR);
    }
}
 public function inspect($wsdlUrl, $methodName = "")
 {
     //		$wsdlUrl = "http://ws.cdyne.com/DemographixWS/DemographixQuery.asmx?wsdl";
     //		$wsdlUrl = "http://ws.cdyne.com/emailverify/Emailvernotestemail.asmx?wsdl";
     //		$wsdlUrl = "http://ws.cdyne.com/NotifyWS/PhoneNotify.asmx?wsdl";
     //		$methodName = "NotifyPhoneBasic";
     $wsdlXml = new DOMDocument();
     $wsdlXml->load($wsdlUrl);
     /*WebServiceDescriptor*/
     $this->serviceDescriptor = new WebServiceDescriptor();
     $this->definitions = $wsdlXml->getElementsByTagName("definitions")->item(0)->childNodes;
     $this->getTypes();
     /*DOMDocument*/
     $service = XmlUtil::getElementByNodeName($this->definitions, "service");
     /*string*/
     $serviceName = $service->documentElement->getAttribute("name");
     $this->serviceDescriptor->setName($serviceName);
     $proxyhost = '';
     $proxyport = '';
     $proxyusername = '';
     $proxypassword = '';
     $client = new soapclient($wsdlUrl, true, $proxyhost, $proxyport, $proxyusername, $proxypassword);
     $err = $client->getError();
     if ($err) {
         throw new Exception($err);
     }
     $operations = $client->getOperations($methodName);
     //		var_dump($operations);
     //		if(LOGGING)
     //			Log::log(LoggingConstants::MYDEBUG, ob_get_contents());
     foreach ($operations as $operation) {
         /*WebServiceMethod*/
         $webServiceMethod = new WebServiceMethod();
         $this->parseMessageInput($operation['input']['message'], $webServiceMethod);
         $webServiceMethod->setReturn($this->parseMessageOutput($operation['output']['message']));
         $webServiceMethod->setName($operation["name"], $webServiceMethod);
         $this->serviceDescriptor->addMethod($webServiceMethod);
     }
 }
Exemple #12
0
 private function query_tran_detail($params)
 {
     $MerchantID = $this->merchantID;
     $ReferenceID = $params['order_sn'];
     $SecretPIN = $this->secret_pin;
     $this->getHeartBeat();
     $HeartBeat = $this->heartbeat;
     $Signature = sha1(strtolower($MerchantID . $ReferenceID . $SecretPIN . $HeartBeat));
     log_message('GASH', 'MOL_WALLET_RETURN_SIGN' . $Signature);
     $soap_param = array();
     //Sandbox
     //     	$soap = 'http://molv3.molsolutions.com/api/login/s_module/querytrxstatus.asmx?WSDL';
     //Live
     $soap = 'https://global.mol.com/api/login/s_module/querytrxstatus.asmx?WSDL';
     $method = 'queryTrxStatus';
     $soap_param = array(array('MerchantID' => $MerchantID, 'MRef_ID' => $ReferenceID, 'HeartBeat' => $HeartBeat, 'Signature' => $Signature));
     $client = new soapclient($soap);
     $client->soap_defencoding = 'UTF-8';
     $client->decode_utf8 = false;
     log_message('GASH', 'MOL_WALLET_SOPA_PARAM' . $soap_param);
     $result = $client->__call($method, $soap_param);
     $result = $result->queryTrxStatusResult;
     log_message("GASH", "MOL_WALLET_QUERY_RESULT" . json_encode($result));
     $msg = "儲值失敗,請聯繫遊戲客服" . $result->ResCode . "Status:" . $result->Status;
     if ($result->ResCode == 100 && $result->Status == 1) {
         $sign = sha1(strtolower($result->ResCode . $MerchantID . $ReferenceID . $SecretPIN . $result->Amount . $result->Currency));
         //     		$msg=$msg."22";
         log_message("GASH", "MOL_WALLET_SUCCESS" . json_encode($result));
         if ($sign == $result->Signature) {
             //     			$msg=$msg."33";
             log_message("GASH", "MOL_WALLET_TRUE_SUCCESS" . json_encode($params));
             if ($this->_complete_order($params)) {
                 $order_info = $this->CI->pay_order->get_recharge_order($params['order_sn']);
                 log_message("GASH", "MOL_WALLET_TRUE_GAME_SUCCESS" . json_encode($params));
                 $msg = "儲值成功";
                 $this->CI->payorder->over($msg, $order_info->order_sn);
                 return;
             }
         }
     }
     $this->CI->payorder->over($msg);
 }
<?php 
if (isset($_POST['send'])) {
    $uname = $_POST['mail'];
    $param12 = array('UserName' => "{$uname}");
    $client12 = new soapclient('http://etypeservices.com/service_GetPublicationIDByUserName.asmx?WSDL');
    $response12 = $client12->GetPublicationID($param12);
    //echo "<pre>";
    //print_r($response12);
    //echo "</pre>";
    if ($response12->GetPublicationIDResult == -9) {
        $msg = "Invalid UserName ";
    } else {
        if ($response12->GetPublicationIDResult == 3053) {
            $param = array('UserName' => $uname);
            $client = new soapclient('http://etypeservices.com/service_ForgetPassword.asmx?WSDL');
            try {
                $response = $client->ForgetPassword($param);
                if ($response->ForgetPasswordResult == 1) {
                    $msg = "Credentials have been sent to your registered email";
                } else {
                    $msg = "User is Not Registered For This Publication";
                }
            } catch (Exception $e) {
                echo '' . $e->getMessage();
            }
        } else {
            $msg = "User Not Exists";
        }
    }
}
?>
Exemple #14
0
 *	WSDL client sample.
 *	Exercises a document/literal NuSOAP service (added nusoap.php 1.73).
 *	Does not explicitly wrap parameters.
 *
 *	Service: WSDL
 *	Payload: document/literal
 *	Transport: http
 *	Authentication: none
 */
require_once '../lib/nusoap.php';
$proxyhost = isset($_POST['proxyhost']) ? $_POST['proxyhost'] : '';
$proxyport = isset($_POST['proxyport']) ? $_POST['proxyport'] : '';
$proxyusername = isset($_POST['proxyusername']) ? $_POST['proxyusername'] : '';
$proxypassword = isset($_POST['proxypassword']) ? $_POST['proxypassword'] : '';
$useCURL = isset($_POST['usecurl']) ? $_POST['usecurl'] : '0';
$client = new soapclient('http://www.scottnichol.com/samples/hellowsdl3.wsdl', true, $proxyhost, $proxyport, $proxyusername, $proxypassword);
$err = $client->getError();
if ($err) {
    echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
}
$client->setUseCurl($useCURL);
$person = array('firstname' => 'Willi', 'age' => 22, 'gender' => 'male');
$name = array('name' => $person);
$result = $client->call('hello', $name);
if ($client->fault) {
    echo '<h2>Fault</h2><pre>';
    print_r($result);
    echo '</pre>';
} else {
    $err = $client->getError();
    if ($err) {
      $state=$_POST['state'];
      $postal=$_POST['postalcode'];
      $phone=$_POST['phone'];
      $publicationid=$_POST['Publication_Id'];
      $planid=$_POST['planId'];
      $date = date("Y-m-d");// current date
      
      $expdate = date('Y-m-d', strtotime("+".$_POST['Period']." ".$_POST['PeriodType'].""));
      
      $param=array('Email' =>"$email",'UserName' =>"$UserName",'Password' =>"$Password",'FirstName' =>"$firstname",'LastName'=>"$lastname",'StreetAddress'=>"$address",'City'=>"$city",'State'=>"$state",'PostalCode'=>"$postal",'Phone'=>"$phone",'ExpiryDate'=>"$expdate",'PublicationID'=>"$publicationid",'SubscriptionPlanID'=>"$planid");
    }*/
// echo "<pre>";
//  print_r($param);
// echo "</pre>";
$publicationid = $_SESSION['Publication_Id'];
$client1 = new soapclient('http://etypeservices.com/Service_GetPublisherPaypalEmailID.asmx?WSDL');
$param1 = array('PublicationID' => "{$publicationid}");
$response1 = $client1->GetPublisherPaypalEmailID($param1);
// echo "<pre>";
//   print_r($response1);
// echo "</pre>";
?>

             <div style="margin-left:30px">

<form name="form2" method="POST" action="http://www.acadiaparishtoday.com/confirm-payment" enctype="multipart/form-data">

                <h3 style="Background:gray;line-height: 2.0em;font-size:16px"><center>REVIEW ORDER</center></h3>
                <div style="">
                    <p>
                        Your order is almost complete. Please review the details below and click 'Continue' if all the information is correct. You may use the 'Back' button to make changes to your order if necessary.
Exemple #16
0
    //获取密码
    $content = trim($_POST[mess]);
    //获取短信内容
    $data = date("Y-m-d H:i:s");
    //获取时间
    $ip = getenv('REMOTE_ADDR');
    //获取IP地址
    while (list($name, $value) = each($_POST[colleague_tel])) {
        //读取要发送的电话号码
        if (is_numeric($value) == true) {
            //判断电话格式是否正确
            $mobilenumber = $value;
            //将获取的电话号码附给变量
            $msgtype = "Text";
            //指定短信为文本格式
            /*向数据库中添加发送短信的记录*/
            $sql = "insert into tb_short(short_ip,short_tel,short_tels,short_content,short_date,short_title)values('{$ip}','{$userid}','{$mobilenumber}','{$content}','{$data}','{$carrier}')";
            $rs = new com("adodb.recordset");
            $rs->open($sql, $conn, 3, 3);
            //执行添加语句
            /*------------------------*/
            include 'nusoap/lib/nusoap.php';
            //读取PHP类文件,实现短信的发送
            /*将数据以数组的形式添加到sendXml方法中*/
            $s = new soapclient('http://smsinter.sina.com.cn/ws/smswebservice0101.wsdl', 'WSDL');
            $s->call('sendXml', array('parameters' => array('carrier' => $carrier, 'userid' => $userid, 'password' => $password, 'mobilenumber' => $mobilenumber, 'content' => $content, 'msgtype' => $msgtype)));
            /*-------------------------------------*/
            echo "<script>alert('短信发送成功!');window.location.href='indexs.php?lmbs=连接短信';</script>";
        }
    }
}
$proxypassword = isset($_POST['proxypassword']) ? $_POST['proxypassword'] : '';
echo 'You must set your own Via Michelin login and password in the source code to run this client!';
exit;
$login = '';
$password = '';
$wsdlurl = 'http://www.viamichelin.com/ws/services/Geocoding?wsdl';
$cache = new wsdlcache('.', 120);
$wsdl = $cache->get($wsdlurl);
if (is_null($wsdl)) {
    $wsdl = new wsdl($wsdlurl, $proxyhost, $proxyport, $proxyusername, $proxypassword);
    $cache->put($wsdl);
} else {
    $wsdl->debug_str = '';
    $wsdl->debug('Retrieved from cache');
}
$client = new soapclient($wsdl, true, $proxyhost, $proxyport, $proxyusername, $proxypassword);
$err = $client->getError();
if ($err) {
    echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
}
$inputAddresses[] = array('address' => '45 Liberty Blvd.', 'cityName' => 'Malvern', 'countryCode' => 'USA', 'postalCode' => '19355', 'stateName' => 'PA');
$geocodingrequest = array('addressesList' => $inputAddresses);
$params = array('request' => $geocodingrequest, 'check' => "{$login}|{$password}");
$result = $client->call('getLocationsList', $params);
// Check for a fault
if ($client->fault) {
    echo '<h2>Fault</h2><pre>';
    print_r($result);
    echo '</pre>';
} else {
    // Check for errors
require_once '../lib/nusoap.php';
require_once '../lib/class.wsdlcache.php';
$proxyhost = isset($_POST['proxyhost']) ? $_POST['proxyhost'] : '';
$proxyport = isset($_POST['proxyport']) ? $_POST['proxyport'] : '';
$proxyusername = isset($_POST['proxyusername']) ? $_POST['proxyusername'] : '';
$proxypassword = isset($_POST['proxypassword']) ? $_POST['proxypassword'] : '';
$cache = new wsdlcache('.', 60);
$wsdl = $cache->get('http://www.xmethods.net/sd/2001/BNQuoteService.wsdl');
if (is_null($wsdl)) {
    $wsdl = new wsdl('http://www.xmethods.net/sd/2001/BNQuoteService.wsdl', $proxyhost, $proxyport, $proxyusername, $proxypassword);
    $cache->put($wsdl);
} else {
    $wsdl->debug_str = '';
    $wsdl->debug('Retrieved from cache');
}
$client = new soapclient($wsdl, true, $proxyhost, $proxyport, $proxyusername, $proxypassword);
$err = $client->getError();
if ($err) {
    echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
}
$params = array('isbn' => '0060188782');
$result = $client->call('getPrice', $params);
// Check for a fault
if ($client->fault) {
    echo '<h2>Fault</h2><pre>';
    print_r($result);
    echo '</pre>';
} else {
    // Check for errors
    $err = $client->getError();
    if ($err) {
 $email = $_POST['email'];
 $UserName = $_POST['name'];
 $Password = $_POST['password'];
 $firstname = $_POST['firstname'];
 $lastname = $_POST['lastname'];
 $address = $_POST['address'];
 $city = $_POST['city'];
 $state = $_POST['state'];
 $postal = $_POST['postalcode'];
 $phone = $_POST['phone'];
 $publicationid = $_SESSION['Publication_Id'];
 $date = date("Y-m-d");
 // current date
 $expdate = date('Y-m-d', strtotime("+1 week"));
 $param = array('Email' => "{$email}", 'UserName' => "{$UserName}", 'Password' => "{$Password}", 'FirstName' => "{$firstname}", 'LastName' => "{$lastname}", 'StreetAddress' => "{$address}", 'City' => "{$city}", 'State' => "{$state}", 'PostalCode' => "{$postal}", 'Phone' => "{$phone}", 'ExpiryDate' => "{$expdate}", 'PublicationID' => "{$publicationid}");
 $client = new soapclient('http://etypeservices.com/Service_PrintSubscription.asmx?wsdl');
 $response = $client->SubscriberRegistration($param);
 if ($response->SubscriberRegistrationResult == -1) {
     $msg = "UserName Already Exits";
 } else {
     if ($response->SubscriberRegistrationResult == -2) {
         $msg = "Some Error On Registration";
     } else {
         if ($response->SubscriberRegistrationResult == 1) {
             $msg = "UserName Already Exits or Email is Blank";
         } else {
             if ($response->SubscriberRegistrationResult == -3) {
                 $msg = "Email Already Registered Against This Publication";
             } else {
                 drupal_goto('custom-login-page');
             }
header('Content-Type: text/html');
$_CLASS['core_user']->user_setup();
require_once SITE_FILE_ROOT . 'includes/nusoap/nusoap.php';
$google_license_key = "dJ5XAtRQFHIlbfutrovVj3TizF1Q2TXP";
$query = get_variable('query', 'POST');
$search_type = get_variable('search_type', 'POST', 0, 'int');
$limit = 10;
if (!$query) {
    script_close();
}
$query_command = $query;
if ($search_type === 1) {
    $query_command .= ' site:viperals.berlios.de';
}
$params = array('key' => (string) $google_license_key, 'q' => (string) $query_command, 'start' => (int) 0, 'maxResults' => (int) $limit, 'filter' => (bool) true, 'restricts' => (string) '', 'safeSearch' => (bool) false, 'lr' => (string) '', 'ie' => 'UTF-8', 'oe' => 'UTF-8');
$client = new soapclient('http://api.google.com/search/beta2');
$result = $client->call('doGoogleSearch', $params, 'urn:GoogleSearch');
if ($client->fault || $client->getError()) {
    script_close();
}
$pagination = generate_pagination('google_search&amp;query=' . urlencode($query) . '&amp;search_type=' . $search_type, $result['estimatedTotalResultsCount'], $limit, 0);
$count = count($result['resultElements']);
$num = 1;
for ($i = 0; $i < $count; $i++) {
    $_CLASS['core_template']->assign_vars_array('google_result', array('num' => $num, 'url' => $result['resultElements'][$i]['URL'], 'title' => $result['resultElements'][$i]['title'], 'snippet' => $result['resultElements'][$i]['snippet']));
    $num++;
}
unset($result);
$params = array('key' => (string) $google_license_key, 'phrase' => (string) $query);
$spelling_suggestion = $client->call('doSpellingSuggestion', $params, 'urn:GoogleSearch');
if (is_array($spelling_suggestion)) {
 $_SESSION['upass'] = $_POST['password'];
 $param12 = array('UserName' => "{$username}");
 $client12 = new soapclient('http://etypeservices.com/service_GetPublicationIDByUserName.asmx?WSDL');
 $response12 = $client12->GetPublicationID($param12);
 // echo "<pre>";
 //        print_r($response12);
 //     echo "</pre>";
 if ($response12->GetPublicationIDResult == -9) {
     $msg = "Invalid UserName and password. ";
 } else {
     if ($response12->GetPublicationIDResult == 315 || $response12->GetPublicationIDResult == 1659 || $response12->GetPublicationIDResult == 1660) {
         $param = array('UserName' => "{$username}", 'Password' => "{$Password}");
         $client = new soapclient('http://etypeservices.com/Service_SubscriberLogin.asmx?WSDL');
         $response = $client->ValidateSubscriber($param);
         $param1 = array('UserName' => "{$username}");
         $client1 = new soapclient('http://etypeservices.com/Get_EmailbyUserName.asmx?WSDL');
         $response1 = $client1->GetSubscriberEmail($param1);
         $query = "select name, uid from users where name='" . $username . "'";
         $qu = db_query($query);
         $userexit = "";
         $useruid = "";
         foreach ($qu as $qu) {
             $userexit = $qu->name;
             $useruid = $qu->uid;
         }
         if ($response->ValidateSubscriberResult == -1) {
             $msg = "Subscription Expire";
         } else {
             global $user;
             if ($user->uid == 0) {
                 if ($userexit != '') {
<?php

#
# Copyright (c) 2008, Jassen Moran. All rights reserved.
# MU Marketing, Inc. Confidential Proprietary.
#
// include the SOAP classes
require_once '../lib/nusoap.php';
// require_once('../include/new_urls/url_factory.tnd.inc.php');
require_once '../include/TicketNetworkWebServices.inc.php';
// require_once('err.php');
echo " Preparing for Import.......";
// create client object
$soapclient = new soapclient($serverpath);
$soapclient->timeout = 500;
$soapclient->response_timeout = 500;
//set soap Action
$method = 'GetTickets';
$soapAction = TND_WS_NAMESPACE . "/" . $method;
# TNServices.asmx?WSDL WorkS!!!!!
$param = array(websiteConfigID => $clientID, numberOfRecords => null, eventID => 721113, lowPrice => null, highPrice => null, ticketGroupID => null, requestedSplit => null, sortDescending => null);
echo "Invoking {$method} method..... ";
$soapclient->debug = 1;
// make the call
$result = $soapclient->call($method, $param, $namespace, $soapAction);
# echo "$soapAction: \nSTART_GET_ERROR\n" . $soapclient->getError() . "\nEND_GET_ERROR\nSTART_DEBUG_STR\n" . $soapclient->debug_str . "\nEND_DEBUG_STR\n";
echo "Done Calling {$soapAction}.";
if ($soapclient->getError() || $soapclient->fault) {
    echo "Error for {$soapAction}: \nSTART_GET_ERROR\n" . $soapclient->getError() . "\nEND_GET_ERROR\nSTART_DEBUG_STR\n" . $soapclient->debug_str . "\nEND_DEBUG_STR\n";
    die('ImportEventsFromTND.php exiting');
} else {
<?php

// Pull in the NuSOAP code
require_once '../lib/nusoap.php';
// Create the client instance
$uri = 'http://localhost/WSDPrac/GoogleMapApp/nusoap/Prac/productWebservice.php?wsdl';
$client = new soapclient($uri, true);
// Check for an error
$err = $client->getError();
if ($err) {
    // Display the error
    echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
    // At this point, you know the call that follows will fail
}
// Call the SOAP method
$person = array('firstname' => 'Willi', 'age' => 22, 'gender' => 'male');
//http://sourceforge.net/p/nusoap/discussion/193579/thread/8464efe4/#3c6d
$result = $client->call('GetProductsByCode', array());
// Check for a fault
if ($client->fault) {
    echo '<h2>Fault</h2><pre>';
    print_r($result);
    echo '</pre>';
} else {
    // Check for errors
    $err = $client->getError();
    if ($err) {
        // Display the error
        echo '<h2>Error</h2><pre>' . $err . '</pre>';
    } else {
        // Display the result
/*
 *	$Id$
 *
 *	WSDL client sample.
 *
 *	Service: WSDL
 *	Payload: rpc/encoded (params as an XML string; cf. wsdlclient3.php)
 *	Transport: http
 *	Authentication: none
 */
require_once '../lib/nusoap.php';
$proxyhost = isset($_POST['proxyhost']) ? $_POST['proxyhost'] : '';
$proxyport = isset($_POST['proxyport']) ? $_POST['proxyport'] : '';
$proxyusername = isset($_POST['proxyusername']) ? $_POST['proxyusername'] : '';
$proxypassword = isset($_POST['proxypassword']) ? $_POST['proxypassword'] : '';
$client = new soapclient('http://www.scottnichol.com/samples/hellowsdl2.php?wsdl', true, $proxyhost, $proxyport, $proxyusername, $proxypassword);
$err = $client->getError();
if ($err) {
    echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
}
$params = '<person xsi:type="tns:Person"><firstname xsi:type="xsd:string">Willi</firstname><age xsi:type="xsd:int">22</age><gender xsi:type="xsd:string">male</gender></person>';
$result = $client->call('hello', $params);
// Check for a fault
if ($client->fault) {
    echo '<h2>Fault</h2><pre>';
    print_r($result);
    echo '</pre>';
} else {
    // Check for errors
    $err = $client->getError();
    if ($err) {
Exemple #25
0
 function CreateHeatmap($login, $password, $inputImage, $viewType, $viewDistance, $analysisOptions, $outputOptions)
 {
     // define the SOAP client using the url for the service
     //$client = new soapclient('http://service.feng-gui.com/soap/api.asmx?WSDL',
     $client = new soapclient('http://fg11.feng-gui.com/soap/api.asmx?WSDL', array('trace' => 1, 'login' => $login, 'password' => $password));
     $param = array('InputImage' => $inputImage, 'ViewType' => $viewType, 'viewDistance' => $viewDistance, 'analysisOptions' => $analysisOptions, 'outputOptions' => $outputOptions);
     $response = array();
     ini_set("default_socket_timeout", 240);
     // PMJ Oct 30 2012 - bump up timeout from 3 minutes to 4 and see what happens
     try {
         $result = $client->ImageAttention($param);
         // passess the results
         if (is_soap_fault($result)) {
             throw new Exception('SOAP heatmap call unsuccessful.');
         }
     } catch (Exception $e) {
         $response = array('success' => false, 'soap_response' => $client->__getLastResponse(), 'response_headers' => $client->__getLastResponseHeaders());
         return $response;
     }
     $response = array('success' => true, 'image_url' => $result->ImageAttentionResult->OutputImage);
     return $response;
 }
Exemple #26
0
-->
</style></head>

<body>
	<h1>Soap Test: Normalize</h1>
	<p>Sample Code</p>
	<pre class="code">
	<code>
require_once('{path_to_soap_library}/nusoap.php');
$c = new soapclient('{path_to_soap_server}/taxamatchsoap.php');
$value = $c->call(
		'normalize'
	,	array('string' => $item)
);
	</code>
	</pre>
<?php 
require_once '../../api/nusoap/lib/nusoap.php';
$p = pathinfo($_SERVER['REQUEST_URI']);
$c = new soapclient('http://' . $_SERVER['SERVER_NAME'] . "/" . $p['dirname'] . '/../../api/taxamatchsoap.php');
print "<p>Here are a list of normalized words.</p>";
$list = array("Carex", "Carex%0A", "Carex%20", "Barbatia (Mesocibota) bistrigata (Dunker, 1866)", "Barbatia (?) bistrigata (Dunker, 1866)", "Aphis [?] ficus Theobald, [1918]");
print "<ul>";
foreach ($list as $item) {
    $value = $c->call('normalize', array('string' => $item));
    print "<li>Input: <b>{$item}</b><br>Response: <b>{$value}</b><br><br></li>";
}
print "</ul>";
?>
</body>
</html>
Exemple #27
0
if (isset($_COOKIE['etype'])) {
    foreach ($_COOKIE["etype"] as $name => $value) {
        $etyp[$name] = $value;
    }
    $decrypted_txt = encrypt_decrypt('decrypt', $etyp['perms']);
    //$pos = strrpos($decrypted_txt , '_');
    //  $username = substr($decrypted_txt , 0, $pos);
    //  $password = substr($decrypted_txt , $pos + 1);
    $pos = strrpos($decrypted_txt, '##');
    $str1 = substr($decrypted_txt, 0, $pos + 1);
    $str2 = substr($decrypted_txt, $pos + 2);
    $pos1 = strrpos($str2, '--');
    $username = substr($str2, 0, $pos1);
    $password = substr($str2, $pos1 + 2);
    $param = array('UserName' => "{$username}", 'Password' => "{$password}");
    $client = new soapclient('http://etypeservices.com/Service_SubscriberLogin.asmx?WSDL');
    $response = $client->ValidateSubscriber($param);
    if ($response->ValidateSubscriberResult == 1) {
        $query = "select name, uid from users where name='" . $username . "'";
        $qu = db_query($query);
        $useruid = "";
        foreach ($qu as $qu) {
            $useruid = $qu->uid;
        }
        global $user;
        $user = user_load($useruid);
        drupal_session_regenerate();
    }
}
function encrypt_decrypt($action, $string)
{
Exemple #28
0
function interworx_GetResellers($params)
{
    $key = $params['serveraccesshash'];
    $api_controller = "/nodeworx/reseller";
    $action = "listIds";
    $input = array();
    $client = new soapclient("https://" . $params['serverip'] . ":2443/nodeworx/soap?wsdl");
    $result = $client->route($key, $api_controller, $action, $input);
    logModuleCall("interworx", $action, $input, $result);
    $resellers = array();
    foreach ($result['payload'] as $reseller) {
        $resellerid = $reseller[0];
        $reselleremail = $reseller[1];
        $reselleremail = explode("(", $reselleremail, 2);
        $reselleremail = $reselleremail[1];
        $reselleremail = substr($reselleremail, 0, 0 - 1);
        $resellers[$reselleremail] = $resellerid;
    }
    return $resellers;
}
<?php 
$publication = 326;
// $param=array("PublicationId" => $_POST['publication']);
$param = array("PublicationId" => "{$publication}");
$client = new soapclient('http://etypeservices.com/Service_GetSubsciptionPlan.asmx?wsdl');
$response = $client->GetSubsciptionPlan($param);
// $_SESSION['Publication_Id'] =$_POST['publication'];
$_SESSION['Publication_Id'] = $publication;
//    echo "<pre>";
//   print_r($response);
?>
<form name="planform" method="POST" action="http://www.techetoday.com/checkout"
      enctype="multipart/form-data">
  <fieldset>
    <style>

      .header1 {
        width: 100%;
        height: auto;
        margin-left: 15px;
      }

      .headertop {
        width: 100%;
        height: auto;
      }

      .headerdown {
        width: 100%;
        height: auto;
      }
Exemple #30
0
<?php

// Pull in the NuSOAP code
require_once 'nusoap.php';
// Create the client instance
$client = new soapclient('http://localhost/phphack/hellowsdl2.php?wsdl', true);
// Check for an error
$err = $client->getError();
if ($err) {
    // Display the error
    echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
    // At this point, you know the call that follows will fail
}
// Call the SOAP method
$person = array('firstname' => 'Willi', 'age' => 22, 'gender' => 'male');
$result = $client->call('hello', array('person' => $person));
// Check for a fault
if ($client->fault) {
    echo '<h2>Fault</h2><pre>';
    print_r($result);
    echo '</pre>';
} else {
    // Check for errors
    $err = $client->getError();
    if ($err) {
        // Display the error
        echo '<h2>Error</h2><pre>' . $err . '</pre>';
    } else {
        // Display the result
        echo '<h2>Result</h2><pre>';
        print_r($result);