本文整理匯總了PHP中Tygh\Http::getCurlInfo方法的典型用法代碼示例。如果您正苦於以下問題:PHP Http::getCurlInfo方法的具體用法?PHP Http::getCurlInfo怎麽用?PHP Http::getCurlInfo使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Tygh\Http
的用法示例。
在下文中一共展示了Http::getCurlInfo方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: _checkMultithreading
/**
* Check if multireading is available on the server
*
* @return bool True if available, false otherwise
*/
private static function _checkMultithreading()
{
if (function_exists('curl_multi_init') && Http::getCurlInfo() == '') {
$allow_multithreading = true;
$h_curl_multi = curl_multi_init();
$threads = array();
} else {
$allow_multithreading = false;
}
return $allow_multithreading;
}
示例2: array
}
return array(CONTROLLER_STATUS_REDIRECT, 'payments.processor?payment_id=' . $_REQUEST['payment_id']);
}
return array(CONTROLLER_STATUS_OK, 'payments.manage');
}
// If any method is selected - show it's settings
if ($mode == 'processor') {
$processor_data = fn_get_processor_data($_REQUEST['payment_id']);
// We're selecting new processor
if (!empty($_REQUEST['processor_id']) && (empty($processor_data['processor_id']) || $processor_data['processor_id'] != $_REQUEST['processor_id'])) {
$processor_data = db_get_row("SELECT * FROM ?:payment_processors WHERE processor_id = ?i", $_REQUEST['processor_id']);
$processor_data['processor_params'] = array();
$processor_data['currencies'] = !empty($processor_data['currencies']) ? explode(',', $processor_data['currencies']) : array();
}
if (!empty($processor_data) && $processor_data['callback'] == "Y") {
Tygh::$app['view']->assign('curl_info', Http::getCurlInfo($processor_data['processor']));
}
if (!empty($processor_data['processor_params']['certificate_filename'])) {
$processor_data['processor_params']['certificate_filename'] = fn_basename($processor_data['processor_params']['certificate_filename']);
}
$view = Tygh::$app['view'];
$processor_template = $processor_data['admin_template'];
if ($view->templateExists('views/payments/components/cc_processors/' . $processor_template)) {
$view->assign('processor_template', 'views/payments/components/cc_processors/' . $processor_template);
} else {
// Check if add-ons have required template
$addons = Registry::get('addons');
foreach ($addons as $addon_id => $addon) {
if ($view->templateExists('addons/' . $addon_id . '/views/payments/components/cc_processors/' . $processor_template)) {
$view->assign('processor_template', 'addons/' . $addon_id . '/views/payments/components/cc_processors/' . $processor_template);
break;
示例3: array
}
return array(CONTROLLER_STATUS_REDIRECT, 'payments.processor?payment_id=' . $_REQUEST['payment_id']);
}
return array(CONTROLLER_STATUS_OK, 'payments.manage');
}
// If any method is selected - show it's settings
if ($mode == 'processor') {
$processor_data = fn_get_processor_data($_REQUEST['payment_id']);
// We're selecting new processor
if (!empty($_REQUEST['processor_id']) && (empty($processor_data['processor_id']) || $processor_data['processor_id'] != $_REQUEST['processor_id'])) {
$processor_data = db_get_row("SELECT * FROM ?:payment_processors WHERE processor_id = ?i", $_REQUEST['processor_id']);
$processor_data['processor_params'] = array();
$processor_data['currencies'] = !empty($processor_data['currencies']) ? explode(',', $processor_data['currencies']) : array();
}
if (!empty($processor_data) && $processor_data['callback'] == "Y") {
Registry::get('view')->assign('curl_info', Http::getCurlInfo($processor_data['processor']));
}
if (!empty($processor_data['processor_params']['certificate_filename'])) {
$processor_data['processor_params']['certificate_filename'] = fn_basename($processor_data['processor_params']['certificate_filename']);
}
$view = Registry::get('view');
$processor_template = $processor_data['admin_template'];
if ($view->templateExists('views/payments/components/cc_processors/' . $processor_template)) {
$view->assign('processor_template', 'views/payments/components/cc_processors/' . $processor_template);
} else {
// Check if add-ons have required template
$addons = Registry::get('addons');
foreach ($addons as $addon_id => $addon) {
if ($view->templateExists('addons/' . $addon_id . '/views/payments/components/cc_processors/' . $processor_template)) {
$view->assign('processor_template', 'addons/' . $addon_id . '/views/payments/components/cc_processors/' . $processor_template);
break;