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


PHP PMA_getParamsForUpdateOrInsert函数代码示例

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


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

示例1: testGetParamsForUpdateOrInsert

 /**
  * Test for PMA_getParamsForUpdateOrInsert
  *
  * @return void
  */
 public function testGetParamsForUpdateOrInsert()
 {
     $_REQUEST['where_clause'] = 'LIMIT 1';
     $_REQUEST['submit_type'] = 'showinsert';
     $result = PMA_getParamsForUpdateOrInsert();
     $this->assertEquals(array(array('LIMIT 1'), true, true, false), $result);
     // case 2 (else)
     unset($_REQUEST['where_clause']);
     $_REQUEST['fields']['multi_edit'] = array('a' => 'b', 'c' => 'd');
     $result = PMA_getParamsForUpdateOrInsert();
     $this->assertEquals(array(array('a', 'c'), false, true, false), $result);
 }
开发者ID:kfjihailong,项目名称:phpMyAdmin,代码行数:17,代码来源:PMA_insert_edit_test.php

示例2: elseif

            if ($_REQUEST['after_insert'] == 'same_insert') {
                $url_params['where_clause'][] = $one_where_clause;
            } elseif ($_REQUEST['after_insert'] == 'edit_next') {
                PMA_setSessionForEditNext($one_where_clause);
            }
        }
    }
}
//get $goto_include for different cases
$goto_include = PMA_getGotoInclude($goto_include);
// Defines the url to return in case of failure of the query
$err_url = PMA_getErrorUrl($url_params);
/**
 * Prepares the update/insert of a row
 */
list($loop_array, $using_key, $is_insert, $is_insertignore) = PMA_getParamsForUpdateOrInsert();
$query = array();
$value_sets = array();
$func_no_param = array('CONNECTION_ID', 'CURRENT_USER', 'CURDATE', 'CURTIME', 'CURRENT_DATE', 'CURRENT_TIME', 'DATABASE', 'LAST_INSERT_ID', 'NOW', 'PI', 'RAND', 'SYSDATE', 'UNIX_TIMESTAMP', 'USER', 'UTC_DATE', 'UTC_TIME', 'UTC_TIMESTAMP', 'UUID', 'UUID_SHORT', 'VERSION');
$func_optional_param = array('RAND', 'UNIX_TIMESTAMP');
$gis_from_text_functions = array('GeomFromText', 'GeomCollFromText', 'LineFromText', 'MLineFromText', 'PointFromText', 'MPointFromText', 'PolyFromText', 'MPolyFromText');
$gis_from_wkb_functions = array('GeomFromWKB', 'GeomCollFromWKB', 'LineFromWKB', 'MLineFromWKB', 'PointFromWKB', 'MPointFromWKB', 'PolyFromWKB', 'MPolyFromWKB');
// to create an object of PMA_File class
require_once './libraries/File.class.php';
//if some posted fields need to be transformed.
$mime_map = PMA_getMIME($GLOBALS['db'], $GLOBALS['table']);
if ($mime_map === false) {
    $mime_map = array();
}
$query_fields = array();
$insert_errors = array();
开发者ID:altesien,项目名称:FinalProject,代码行数:31,代码来源:tbl_replace.php

示例3: PMA_setSessionForEditNext

                PMA_setSessionForEditNext($one_where_clause);
            }
        }
    }
}
//get $goto_include for different cases
$goto_include = PMA_getGotoInclude($goto_include);

// Defines the url to return in case of failure of the query
$err_url = PMA_getErrorUrl($url_params);

/**
 * Prepares the update/insert of a row
 */
list($loop_array, $using_key, $is_insert, $is_insertignore)
    = PMA_getParamsForUpdateOrInsert();

$query = array();
$value_sets = array();
$func_no_param = array(
    'CONNECTION_ID',
    'CURRENT_USER',
    'CURDATE',
    'CURTIME',
    'CURRENT_DATE',
    'CURRENT_TIME',
    'DATABASE',
    'LAST_INSERT_ID',
    'NOW',
    'PI',
    'RAND',
开发者ID:nhodges,项目名称:phpmyadmin,代码行数:31,代码来源:tbl_replace.php


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