本文整理匯總了PHP中xajaxResponse::removeScript方法的典型用法代碼示例。如果您正苦於以下問題:PHP xajaxResponse::removeScript方法的具體用法?PHP xajaxResponse::removeScript怎麽用?PHP xajaxResponse::removeScript使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類xajaxResponse
的用法示例。
在下文中一共展示了xajaxResponse::removeScript方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: plugin
function plugin($template, $customer)
{
global $documents_dirs;
$result = '';
// xajax response object, can be used in the plugin
$JSResponse = new xajaxResponse();
foreach ($documents_dirs as $doc) {
if (file_exists($doc . DIRECTORY_SEPARATOR . 'templates' . DIRECTORY_SEPARATOR . $template)) {
$doc_dir = $doc;
continue;
}
}
// read template information
if (file_exists($file = $doc_dir . DIRECTORY_SEPARATOR . 'templates' . DIRECTORY_SEPARATOR . $template . DIRECTORY_SEPARATOR . 'info.php')) {
include $file;
}
// call plugin
if (!empty($engine['plugin'])) {
if (file_exists($file = $doc_dir . DIRECTORY_SEPARATOR . 'templates' . DIRECTORY_SEPARATOR . $engine['name'] . DIRECTORY_SEPARATOR . $engine['plugin'] . '.php')) {
include $file;
}
if (file_exists($doc_dir . DIRECTORY_SEPARATOR . 'templates' . DIRECTORY_SEPARATOR . $engine['name'] . DIRECTORY_SEPARATOR . $engine['plugin'] . '.js')) {
$JSResponse->removeScript($_SERVER['REQUEST_URI'] . '&template=' . $template);
$JSResponse->includeScript($_SERVER['REQUEST_URI'] . '&template=' . $template);
}
}
$JSResponse->assign('plugin', 'innerHTML', $result);
$JSResponse->assign('title', 'value', isset($engine['form_title']) ? $engine['form_title'] : $engine['title']);
return $JSResponse;
}