當前位置: 首頁>>代碼示例>>PHP>>正文


PHP BitBase::verifyIdParameter方法代碼示例

本文整理匯總了PHP中BitBase::verifyIdParameter方法的典型用法代碼示例。如果您正苦於以下問題:PHP BitBase::verifyIdParameter方法的具體用法?PHP BitBase::verifyIdParameter怎麽用?PHP BitBase::verifyIdParameter使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在BitBase的用法示例。


在下文中一共展示了BitBase::verifyIdParameter方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: getIdParameter

 /**
  * getIdParameter Gets an in-bounds, integer hash value it exists, or returns an optional default
  *
  * @param associativearray $pParamHash Hash of key=>value pairs
  * @param string $pHashKey Key used to search for value
  * @param string $pDefault Default value to return if not found. NULL if nothing is passed in.
  * @access public
  * @return TRUE if the input was numeric, FALSE if it wasn't
  */
 public static function getIdParameter(&$pParamHash, $pKey, $pDefaultValue = NULL)
 {
     if (BitBase::verifyIdParameter($pParamHash, $pKey)) {
         $ret = $pParamHash[$pKey];
     } else {
         $ret = $pDefaultValue;
     }
     return $ret;
 }
開發者ID:bitweaver,項目名稱:kernel,代碼行數:18,代碼來源:BitBase.php

示例2: array

// |                                                                      |
// | Portions Copyright (c) 2003 osCommerce                               |
// +----------------------------------------------------------------------+
// | This source file is subject to version 2.0 of the GPL license,       |
// | that is bundled with this package in the file LICENSE, and is        |
// | available through the world-wide-web at the following url:           |
// | http://www.zen-cart.com/license/2_0.txt.                             |
// | If you did not receive a copy of the zen-cart license and are unable |
// | to obtain it through the world-wide-web, please send a note to       |
// | license@zen-cart.com so we can mail you a copy immediately.          |
// +----------------------------------------------------------------------+
//  $Id$
//
require 'includes/application_top.php';
$action = BitBase::getParameter($_GET, 'action');
if ($productTypeId = BitBase::verifyIdParameter($_REQUEST, 'ptID')) {
    $productTypeHash = $gBitDb->GetRow("SELECT `type_name` FROM " . TABLE_PRODUCT_TYPES . " WHERE `type_id` = ?", array($productTypeId));
}
if (zen_not_null($action)) {
    switch ($action) {
        case 'layout_save':
            // demo active test
            if (zen_admin_demo()) {
                $_GET['action'] = '';
                $messageStack->add_session(ERROR_ADMIN_DEMO, 'caution');
                zen_redirect(zen_href_link_admin(FILENAME_PRODUCT_TYPE_LAYOUT, 'gID=' . $_GET['gID'] . '&cID=' . $cID));
            }
            $configuration_value = zen_db_prepare_input($_POST['configuration_value']);
            $cID = zen_db_prepare_input($_GET['cID']);
            $gBitDb->Execute("update " . TABLE_PRODUCT_TYPE_LAYOUT . "\n\t\t\t\t\t\t\t\t\t\tset `configuration_value` = '" . zen_db_input($configuration_value) . "',\n\t\t\t\t\t\t\t\t\t\t\t\t`last_modified` = " . $gBitDb->qtNOW() . " where configuration_id = '" . (int) $cID . "'");
            $configuration_query = 'select configuration_key as cfgkey, configuration_value as cfgvalue
開發者ID:bitweaver,項目名稱:commerce,代碼行數:31,代碼來源:product_types.php

示例3: getDisplayUrlFromHash

 /**
  * Function that returns link to display a piece of content
  * @param pGalleryId id of gallery to link
  * @return the url to display the gallery.
  */
 public static function getDisplayUrlFromHash(&$pParamHash)
 {
     $path = NULL;
     if (BitBase::verifyIdParameter($pParamHash, 'gallery_id')) {
         $ret = FISHEYE_PKG_URL;
         global $gBitSystem;
         if ($gBitSystem->isFeatureActive('pretty_urls')) {
             $ret .= 'gallery' . $path . '/' . $pParamHash['gallery_id'];
         } else {
             $ret .= 'view.php?gallery_id=' . $pParamHash['gallery_id'];
             if (!empty($pHash['path'])) {
                 $ret .= '&gallery_path=' . $pParamHash['path'];
             }
         }
     } elseif (@BitBase::verifyId($pParamHash['content_id'])) {
         $ret = FISHEYE_PKG_URL . 'view.php?content_id=' . $pParamHash['content_id'];
     }
     return $ret;
 }
開發者ID:bitweaver,項目名稱:fisheye,代碼行數:24,代碼來源:FisheyeGallery.php


注:本文中的BitBase::verifyIdParameter方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。