当前位置: 首页>>代码示例>>PHP>>正文


PHP KT_getResource函数代码示例

本文整理汇总了PHP中KT_getResource函数的典型用法代码示例。如果您正苦于以下问题:PHP KT_getResource函数的具体用法?PHP KT_getResource怎么用?PHP KT_getResource使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了KT_getResource函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: mxi_includes_end

function mxi_includes_end()
{
    $content = ob_get_contents();
    ob_end_clean();
    $tmpArr = array_pop($GLOBALS['KT_dir_depth']);
    $GLOBALS['KT_REL_PATH'] = $tmpArr['relpath'];
    // dirty hack IIS
    $chk = true;
    if (substr($tmpArr['dir'], 0, strlen($tmpArr['dir']) - 1) !== realpath(dirname(__FILE__) . '/../../')) {
        $chk = chdir($tmpArr['dir']);
    } elseif (getcwd() !== realpath(dirname(__FILE__) . '/../../')) {
        chdir(realpath(dirname(__FILE__)));
        $chk = chdir('../../');
    }
    if ($chk === false) {
        die(KT_getResource('PHP_CHDIR_FAILED', 'MXI', array($tmpArr['dirRelPath'])));
    }
    $content = mxi_ParseHtml($content, $tmpArr['relpath']);
    $GLOBALS['KT_REL_PATH'] = $GLOBALS['KT_dir_depth'][count($GLOBALS['KT_dir_depth']) - 1]['relpath'];
    echo $content;
    if (isset($GLOBALS['arrTNGs']) && count($GLOBALS['arrTNGs']) > 0) {
        $GLOBALS['tNGs'] = array_pop($GLOBALS['arrTNGs']);
    }
}
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:24,代码来源:MXI_functions.inc.php

示例2: IncludeDynamic

 function IncludeDynamic(&$connection, $tableName, $urlField, $fileField, $titleField, $keywordsField, $descriptionField)
 {
     KT_setDbType($connection);
     $sql = "SELECT " . KT_escapeFieldName($urlField) . "," . KT_escapeFieldName($fileField);
     if ($titleField != "") {
         $sql .= "," . KT_escapeFieldName($titleField);
     }
     if ($keywordsField != "") {
         $sql .= "," . KT_escapeFieldName($keywordsField);
     }
     if ($descriptionField != "") {
         $sql .= "," . KT_escapeFieldName($descriptionField);
     }
     $sql .= " FROM " . $tableName;
     $localRs = $connection->Execute($sql);
     if (!$localRs) {
         $res_errorMsg = KT_getResource('SQL_ERROR', 'MXI', array($connection->ErrorMsg(), $sql));
         die($res_errorMsg);
     }
     $this->IncludeDynamicRecordset($localRs, $urlField, $fileField, $titleField, $keywordsField, $descriptionField);
 }
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:21,代码来源:MXI_Includes.class.php

示例3: dirname

/*
 * ADOBE SYSTEMS INCORPORATED
 * Copyright 2007 Adobe Systems Incorporated
 * All Rights Reserved
 * 
 * NOTICE:  Adobe permits you to use, modify, and distribute this file in accordance with the 
 * terms of the Adobe license agreement accompanying it. If you have received this file from a 
 * source other than Adobe, then your use, modification, or distribution of it requires the prior 
 * written permission of Adobe.
 */
/*
	Copyright (c) InterAKT Online 2000-2006. All rights reserved.
*/
include_once dirname(realpath(__FILE__)) . '/../../common/lib/resources/KT_Resources.php';
$d = 'NXT';
KT_sendExpireHeader(60 * 60 * 24);
header("Content-Type: application/JavaScript");
?>
//Javascript UniVAL Resources
if (typeof(NXT_Messages) == 'undefined') {
	NXT_Messages = {};
}
NXT_Messages['are_you_sure_move'] = '<?php 
echo KT_escapeJS(KT_getResource('ARE_YOU_SURE_MOVE', $d));
?>
';
NXT_Messages['Record_FH'] = '<?php 
echo KT_escapeJS(KT_getResource('Record_FH', $d));
?>
';
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:30,代码来源:form.js.php

示例4: getErrorMsg

 /**
  * Gets the error message
  * @return string transaction error message (formatted)
  * @access public
  */
 function getErrorMsg()
 {
     $ret_warning = '';
     if (isset($this->noSuccess) && $this->noSuccess != 0) {
         $ret_warning = KT_getResource('MULTIPLE_OPERATIONS_SUCCEDED', 'tNG', array($this->noSuccess));
     }
     if (!$this->getError()) {
         return array($ret_warning, '', '');
     }
     $this->compileError();
     $ret = parent::getErrorMsg();
     $ret[0] .= $ret_warning;
     return $ret;
 }
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:19,代码来源:tNG_multiple.class.php

示例5: Trigger_Registration_CheckUniqueUsername

function Trigger_Registration_CheckUniqueUsername(&$tNG)
{
    $tblFldObj = new tNG_CheckUnique($tNG);
    $tblFldObj->setTable($GLOBALS['tNG_login_config']['table']);
    $tblFldObj->setFieldName($GLOBALS['tNG_login_config']['user_field']);
    $tblFldObj->setErrorMsg(KT_getResource("REGISTRATION_UNIQUE_USER_FIELDERR", "tNG"));
    return $tblFldObj->Execute();
}
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:8,代码来源:tNG_defTrigg.inc.php

示例6: KT_getResource

        echo KT_getResource('DELETE', 'tNG');
        ?>
" class="KT_delete_link button_smallest" onClick = "if (!confirm('Are you sure you want to delete?')) return false;" />
					</form>
					</td>
			</tr>
<?php 
        $rsFiles->MoveNext();
    }
    ?>
  <?php 
}
// Show if recordset not empty
?>
		</table>

</div>
<div class="bottom" >
<table width="100%" class="KT_tngtable" cellpadding="0" cellspacing="0">
<tr class="KT_buttons">
        <th>
            <input type="button" value="<?php 
echo KT_getResource('CLOSE', 'tNG');
?>
" onClick = "window.close()" />
        </th>
    </tr>
</table>
</div>
</body>
</html>
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:31,代码来源:multiple_upload.php

示例7: setError

 /**
  * Setter. set error for developper and user.
  * @var string $errorCode error message code;
  * @var array $arrArgsUsr  array with optional parameters for sprintf functions;
  * @var array $arrArgsDev array with optional parameters for sprintf functions.
  * @return nothing;
  * @access private
  */
 function setError($errorCode, $arrArgsUsr, $arrArgsDev)
 {
     $errorCodeDev = $errorCode;
     if (!in_array($errorCodeDev, array('', '%s'))) {
         $errorCodeDev .= '_D';
     }
     if ($errorCode != '') {
         $this->errorType[] = KT_getResource($errorCode, 'FileUpload', $arrArgsUsr);
     } else {
         $this->errorType = array();
     }
     if ($errorCodeDev != '') {
         $this->develErrorMessage[] = KT_getResource($errorCodeDev, 'FileUpload', $arrArgsDev);
     } else {
         $this->develErrorMessage = array();
     }
 }
开发者ID:nadavkav,项目名称:MoodleTAO,代码行数:25,代码来源:KT_FileUpload.class.php

示例8: execTidy

 /**
  * executes tidy and gets the value
  * @param string column name from transaction
  * @param string string to test
  * @return boolean true if tidy executed succesfully
  * @access private
  */
 function execTidy($colName, $value)
 {
     $arg_test = array('--version');
     if (isset($_SESSION['TidyContent']['ExecPath'])) {
         $loc = array($_SESSION['TidyContent']['ExecPath']);
     } else {
         $loc = $GLOBALS['TidyContent_TidyLocations'];
         if (isset($GLOBALS['KT_prefered_tidy_path'])) {
             array_unshift($loc, $GLOBALS['KT_prefered_tidy_path'] . 'tidy');
             array_unshift($loc, $GLOBALS['KT_prefered_tidy_path'] . 'tidy.exe');
         }
     }
     $shell = new KT_shell();
     $shell->execute($loc, $arg_test);
     if ($shell->hasError()) {
         $arr = $shell->getError();
         $this->setErrorMsg($arr[0], $arr[1]);
         return false;
     }
     $execPath = $shell->getExecutedCommand();
     if (!isset($_SESSION['TidyContent']['ExecPath']) && $execPath != '') {
         $_SESSION['TidyContent']['ExecPath'] = $execPath;
         $loc = array($execPath);
     }
     $tidyEncoding = 'raw';
     if (strtolower($this->outEncoding) == 'iso-8859-1') {
         $tidyEncoding = 'ascii';
     }
     if (strpos(strtolower($this->outEncoding), 'utf-8') !== false) {
         $tidyEncoding = 'utf8';
     }
     $string = $value;
     $string = str_replace("&amp;nbsp;", "&amp;amp;nbsp;", $string);
     $string = str_replace("&nbsp;", "&amp;nbsp;", $string);
     if (!file_exists($this->folderName)) {
         $folder = new KT_folder();
         $folder->createFolder($this->folderName);
         if ($folder->hasError()) {
             $arr = $folder->getError();
             $this->setErrorMsg($arr[0], $arr[1]);
             return false;
         }
     }
     $f = tempnam(substr($this->folderName, 0, -1), 'tidy');
     if ($f === false) {
         $err = KT_getResource('ERROR_TIDY_CONTENT', 'tNG', array());
         $this->setErrorMsg($err, $err);
         return false;
     }
     $fout = $f . '_out';
     $file = new KT_file();
     $file->writeFile($f, 'append', $string);
     if ($file->hasError()) {
         $arr = $file->getError();
         $this->setErrorMsg($arr[0], $arr[1]);
         return false;
     }
     $path = $GLOBALS['TidyContent_TidyConfiguration'];
     $arg = array("-config", $path, '-' . $tidyEncoding, "-o", $fout, $f);
     $shell = new KT_shell();
     $output = $shell->execute($loc, $arg);
     if ($shell->hasError() && !file_exists($fout)) {
         $arr = $shell->getError();
         $this->setErrorMsg($arr[0], $arr[1]);
         @unlink($f);
         @unlink($fout);
         return false;
     }
     $file = new KT_file();
     $content = $file->readFile($fout);
     if ($file->hasError()) {
         $arr = $file->getError();
         $this->setErrorMsg($arr[0], $arr[1]);
         @unlink($f);
         @unlink($fout);
         return false;
     }
     $file->deleteFile($f);
     if ($file->hasError()) {
         $arr = $file->getError();
         $this->setErrorMsg($arr[0], $arr[1]);
         @unlink($fout);
         return false;
     }
     $file->deleteFile($fout);
     if ($file->hasError()) {
         $arr = $file->getError();
         $this->setErrorMsg($arr[0], $arr[1]);
         return false;
     }
     $content = str_replace("&amp;nbsp;", "&nbsp;", $content);
     $content = str_replace("&amp;amp;nbsp;", "&amp;nbsp;", $content);
     $content = $this->cleanContent($content);
//.........这里部分代码省略.........
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:101,代码来源:tNG_TidyContent.class.php

示例9: getLoginMsg

 /**
  * Returns the messages for the Login Page
  * @access public
  */
 function getLoginMsg()
 {
     $show = false;
     for ($i = 0; $i < $this->n; $i++) {
         if ($this->tNGs[$i]->getTransactionType() == '_login' && !$this->tNGs[$i]->started) {
             $show = true;
             break;
         }
     }
     if ($show) {
         $info_resources = array('REG_ACTIVATE', 'REG_EMAIL', 'REG', 'ACTIVATED', 'FORGOT', 'DENIED', 'MAXTRIES', 'ACCOUNT_EXPIRE');
         $info_key = KT_getRealValue("GET", "info");
         if ($info_key != "") {
             if (in_array($info_key, $info_resources)) {
                 $ret = '<div id="KT_tngdeverror">';
                 $ret .= '<label>' . KT_getResource('LOGIN_MESSAGE_LABEL', 'tNG') . '</label>';
                 $ret .= '<div>' . KT_getResource('LOGIN_MESSAGE__' . $info_key, 'tNG') . '</div>';
                 $ret .= '</div>';
                 return $ret;
             }
         }
     }
     return '';
 }
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:28,代码来源:tNG_dispatcher.class.php

示例10: loadGenericValidationMessages

 function loadGenericValidationMessages(&$arr)
 {
     $d = 'tNG_FormValidation';
     $arr["failed"] = KT_getResource('FAILED', $d);
     $arr["required"] = KT_getResource('REQUIRED', $d);
     $arr["type"] = KT_getResource('TYPE', $d);
     $arr["format"] = KT_getResource('FORMAT', $d);
     $arr["text_"] = KT_getResource('TEXT_', $d);
     $arr["text_email"] = KT_getResource('TEXT_EMAIL', $d);
     $arr["text_cc_generic"] = KT_getResource('TEXT_CC_GENERIC', $d);
     $arr["text_cc_visa"] = KT_getResource('TEXT_CC_VISA', $d);
     $arr["text_cc_mastercard"] = KT_getResource('TEXT_CC_MASTERCARD', $d);
     $arr["text_cc_americanexpress"] = KT_getResource('TEXT_CC_AMERICANEXPRESS', $d);
     $arr["text_cc_discover"] = KT_getResource('TEXT_CC_DISCOVER', $d);
     $arr["text_cc_dinersclub"] = KT_getResource('TEXT_CC_DINERSCLUB', $d);
     $arr["text_zip_generic"] = KT_getResource('TEXT_ZIP_GENERIC', $d);
     $arr["text_zip_us5"] = KT_getResource('TEXT_ZIP_US5', $d);
     $arr["text_zip_us9"] = KT_getResource('TEXT_ZIP_US9', $d);
     $arr["text_zip_canada"] = KT_getResource('TEXT_ZIP_CANADA', $d);
     $arr["text_zip_uk"] = KT_getResource('TEXT_ZIP_UK', $d);
     $arr["text_phone"] = KT_getResource('TEXT_PHONE', $d);
     $arr["text_ssn"] = KT_getResource('TEXT_SSN', $d);
     $arr["text_url"] = KT_getResource('TEXT_URL', $d);
     $arr["text_ip"] = KT_getResource('TEXT_IP', $d);
     $arr["text_color_hex"] = KT_getResource('TEXT_COLOR_HEX', $d);
     $arr["text_color_generic"] = KT_getResource('TEXT_COLOR_GENERIC', $d);
     $arr["numeric_"] = KT_getResource('NUMERIC_', $d);
     $arr["numeric_int"] = KT_getResource('NUMERIC_INT', $d);
     $arr["numeric_int_positive"] = KT_getResource('NUMERIC_INT_POSITIVE', $d);
     $arr["numeric_zip_generic"] = KT_getResource('TEXT_ZIP_GENERIC', $d);
     $arr["double_"] = KT_getResource('DOUBLE_', $d);
     $arr["double_float"] = KT_getResource('DOUBLE_FLOAT', $d);
     $arr["double_float_positive"] = KT_getResource('DOUBLE_FLOAT_POSITIVE', $d);
     $arr["date_"] = KT_getResource('DATE_', $d);
     $arr["date_date"] = KT_getResource('DATE_DATE', $d);
     $arr["date_time"] = KT_getResource('DATE_TIME', $d);
     $arr["date_datetime"] = KT_getResource('DATE_DATETIME', $d);
     $arr["mask_"] = KT_getResource('MASK_', $d);
     $arr["regexp_"] = KT_getResource('REGEXP_', $d);
     $arr["regexp_failed"] = KT_getResource('REGEXP_FAILED', $d);
     $arr["text_min"] = KT_getResource('TEXT_MIN', $d);
     $arr["text_max"] = KT_getResource('TEXT_MAX', $d);
     $arr["text_between"] = KT_getResource('TEXT_BETWEEN', $d);
     $arr["other_min"] = KT_getResource('OTHER_MIN', $d);
     $arr["other_max"] = KT_getResource('OTHER_MAX', $d);
     $arr["other_between"] = KT_getResource('OTHER_BETWEEN', $d);
 }
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:47,代码来源:tNG_FormValidation.class.php

示例11: KT_getResource

                    $err[1] .= '<br/>' . $arr[1];
                    if (isset($_GET['isFlash'])) {
                        !isset($_SESSION['tng_upload']['errorForFlash']) ? $_SESSION['tng_upload']['errorForFlash'] = '' : '';
                        if ($GLOBALS['tNG_debug_mode'] == 'DEVELOPMENT') {
                            $_SESSION['tng_upload']['errorForFlash'] .= $err[1] . '<br/>';
                        } else {
                            $_SESSION['tng_upload']['errorForFlash'] .= $err[0] . '<br/>';
                        }
                    }
                }
            }
        }
    } else {
        if (isset($_GET['isFlash'])) {
            !isset($_SESSION['tng_upload']['errorForFlash']) ? $_SESSION['tng_upload']['errorForFlash'] = '' : '';
            $_SESSION['tng_upload']['errorForFlash'] .= KT_getResource('MAX_FILES_NO_REACHED', 'tNG', array($uploadHash['maxFiles'])) . '<br/>';
        }
    }
}
// end page execution if we are calling from flash;
if (isset($_GET['isFlash'])) {
    echo " ";
    exit;
}
//folder recordset
$listFolder = new tNG_FileListRecordset("../../../", $KT_conn_mupload);
$listFolder->setBaseFolder($folder);
$listFolder->setFolder("");
$listFolder->setAllowedExtensions(implode(',', $uploadHash['allowedExtensions']));
$listFolder->setOrder('name', 'ASC');
//create the fake recordset
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:31,代码来源:multiple_upload.inc.php

示例12: KT_getResource

						  <?php 
    }
    // endif Conditional region4
    ?>
			</li>
		</ul>
	</div>
</div>
  <?php 
}
// endif Conditional region1
// Show IF Conditional region5
if (isset($err) && $GLOBALS['tNG_debug_mode'] == 'DEVELOPMENT') {
    ?>
	<div id="KT_tngerror"><label><?php 
    echo KT_getResource('ERROR_LABEL', 'tNG');
    ?>
</label>
		<div><?php 
    echo $err[1];
    ?>
</div>
	</div>
<?php 
}
// endif Conditional region5
?>
<table width="100%" height="96%">
	<tr>
		<td align="center">
<a href="#" onClick="window.close()" title="Click to Close">
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:31,代码来源:popup_image.php

示例13: getMySQL4fakeRS

 /**
  * Gets a MySQL recordset (resource id). Optimized for mysql version 4 or higher.
  * @return integer
  * @access private
  */
 function getMySQL4fakeRS()
 {
     $fields = array();
     $i = 0;
     $select_sql = '';
     foreach ($this->fields as $key => $value) {
         $i = 0;
         if (!is_array($value)) {
             $fields[$i][$key] = $value;
         } else {
             foreach ($value as $key2 => $val) {
                 $fields[$i][$key] = $val;
                 $i++;
             }
         }
     }
     for ($i = 0; $i < count($fields); $i++) {
         $row = $fields[$i];
         if ($i > 0) {
             $select_sql .= ' UNION ALL ';
         }
         $select_sql .= 'SELECT ';
         foreach ($row as $colName => $value) {
             $select_sql .= "'" . mysql_escape_string($value) . "' AS " . $colName . ", ";
         }
         $select_sql = substr(trim($select_sql), 0, -1);
     }
     if ($select_sql == '') {
         $select_sql = "SELECT * FROM (SELECT 1 AS tmp) AS tmptable where tmptable.tmp = 2";
     }
     $result = $this->connection->MySQL_Execute($select_sql);
     if ($result === false) {
         $this->error = KT_getResource('PHP_DB_SELECT_UNION_D', 'DB', array($this->connection->ErrorMsg(), $select_sql));
         $this->hasError = true;
         return null;
     }
     return $result;
 }
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:43,代码来源:KT_FakeRecordset.class.php

示例14: KT_escapeJS

echo KT_escapeJS(KT_getResource('the_date_format_is', $d));
?>
';
WDG_Messages['calendar_button']       = '<?php 
echo KT_escapeJS(KT_getResource('calendar_button', $d));
?>
';
WDG_Messages['calendar_button']       = '<?php 
echo KT_escapeJS(KT_getResource('calendar_button', $d));
?>
';
WDG_Messages['rte_maximum_reached']   = '<?php 
echo KT_escapeJS(KT_getResource('rte_maximum_reached', $d));
?>
';
WDG_Messages['dyn_add_label_text']    = '<?php 
echo KT_escapeJS(KT_getResource('dyn_add_label_text', $d));
?>
';
WDG_Messages['dyn_are_you_sure_text'] = '<?php 
echo KT_escapeJS(KT_getResource('dyn_are_you_sure_text', $d));
?>
';
WDG_Messages['dyn_submit_text']       = '<?php 
echo KT_escapeJS(KT_getResource('dyn_submit_text', $d));
?>
';
WDG_Messages['dyn_default_option_text'] = '<?php 
echo KT_escapeJS(KT_getResource('dyn_default_option_text', $d));
?>
';
开发者ID:Vinhbaba,项目名称:871128qlchbs,代码行数:31,代码来源:MXWidgets.js.php

示例15: getErrorMsg

 /**
  * Gets the error message
  * Adds the import specific messages, then calls the parent getErrorMsg method.
  * @return string transaction error message (formatted)
  * @access public
  */
 function getErrorMsg()
 {
     $ret_warning = '';
     if (isset($this->noSkip) && $this->noSkip != 0) {
         $ret_warning = KT_getResource('IMPORT_OPERATIONS_SKIPPED', 'tNG', array($this->noSkip));
     }
     $ret = parent::getErrorMsg();
     $ret[0] .= $ret_warning;
     $ret[0] = trim($ret[0]);
     return $ret;
 }
开发者ID:Mayoh,项目名称:grupo-ha,代码行数:17,代码来源:tNG_import.class.php


注:本文中的KT_getResource函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。