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


PHP PMA_getHtmlForActionRowInStructureTable函数代码示例

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


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

示例1: PMA_getHtmlForActionsInTableStructure

/**
 * Get HTML snippet for Actions in table structure
 *
 * @param string         $type                      column type
 * @param string         $tbl_storage_engine        table storage engine
 * @param object|boolean $primary                   primary if set,
 *                                                  false otherwise
 * @param string         $field_name                column name
 * @param string         $url_query                 url query
 * @param array          $titles                    titles array
 * @param array          $row                       current row
 * @param string         $rownum                    row number
 * @param array          $columns_with_unique_index columns with unique index
 * @param boolean        $isInCentralColumns        set if column in central
 *                                                  columns list
 *
 * @return string $html_output;
 */
function PMA_getHtmlForActionsInTableStructure($type, $tbl_storage_engine, $primary, $field_name, $url_query, $titles, $row, $rownum, $columns_with_unique_index, $isInCentralColumns)
{
    $html_output = '<td><ul class="table-structure-actions resizable-menu">';
    $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'primary nowrap', $primary && $primary->hasColumn($field_name), true, $url_query, $primary, 'ADD PRIMARY KEY', __('A primary key has been added on %s.'), 'Primary', $titles, $row, true);
    $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'add_unique unique nowrap', isset($columns_with_unique_index[$field_name]), false, $url_query, $primary, 'ADD UNIQUE', __('An index has been added on %s.'), 'Unique', $titles, $row, false);
    $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'add_index nowrap', false, false, $url_query, $primary, 'ADD INDEX', __('An index has been added on %s.'), 'Index', $titles, $row, false);
    if (!PMA_DRIZZLE) {
        $spatial_types = array('geometry', 'point', 'linestring', 'polygon', 'multipoint', 'multilinestring', 'multipolygon', 'geomtrycollection');
        $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'spatial nowrap', !in_array($type, $spatial_types) || 'MYISAM' != $tbl_storage_engine, false, $url_query, $primary, 'ADD SPATIAL', __('An index has been added on %s.'), 'Spatial', $titles, $row, false);
        // FULLTEXT is possible on TEXT, CHAR and VARCHAR
        $html_output .= PMA_getHtmlForFullTextAction($tbl_storage_engine, $type, $url_query, $row, $titles);
    }
    $html_output .= PMA_getHtmlForDistinctValueAction($url_query, $row, $titles);
    if (isset($GLOBALS['cfgRelation']['central_columnswork']) && $GLOBALS['cfgRelation']['central_columnswork']) {
        $html_output .= '<li class="browse nowrap">';
        if ($isInCentralColumns) {
            $html_output .= '<a href="#" onclick=$("input:checkbox").prop("checked",false);' . '$("#checkbox_row_' . $rownum . '").prop("checked",true);' . '$("button[value=remove_from_central_columns]").click();>' . PMA_Util::getIcon('centralColumns_delete.png', __('Remove from central columns')) . '</a>';
        } else {
            $html_output .= '<a href="#" onclick=$("input:checkbox").prop("checked",false);' . '$("#checkbox_row_' . $rownum . '").prop("checked",true);' . '$("button[value=add_to_central_columns]").click();>' . PMA_Util::getIcon('centralColumns_add.png', __('Add to central columns')) . '</a>';
        }
        $html_output .= '</li>';
    }
    $html_output .= '</ul></td>';
    return $html_output;
}
开发者ID:tecshuttle,项目名称:51qsk,代码行数:43,代码来源:structure.lib.php

示例2: PMA_getHtmlForActionsInTableStructure

/**
 * Get HTML snippet for Actions in table structure
 *
 * @param string  $type                      column type
 * @param string  $tbl_storage_engine        table storage engine
 * @param boolean $primary                   primary if set, false otherwise
 * @param string  $field_name                column name
 * @param string  $url_query                 url query
 * @param array   $titles                    titles array
 * @param array   $row                       current row
 * @param string  $rownum                    row number
 * @param array   $hidden_titles             hidden titles
 * @param array   $columns_with_unique_index columns with unique index
 *
 * @return string $html_output;
 */
function PMA_getHtmlForActionsInTableStructure($type, $tbl_storage_engine, $primary, $field_name, $url_query, $titles, $row, $rownum, $hidden_titles, $columns_with_unique_index)
{
    $html_output = '<td><ul class="table-structure-actions resizable-menu">';
    $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'primary nowrap', $primary && $primary->hasColumn($field_name), true, $url_query, $primary, 'ADD PRIMARY KEY', __('A primary key has been added on %s.'), 'Primary', $titles, $row, true);
    $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'add_unique unique nowrap', isset($columns_with_unique_index[$field_name]), false, $url_query, $primary, 'ADD UNIQUE', __('An index has been added on %s.'), 'Unique', $titles, $row, false);
    $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'add_index nowrap', false, false, $url_query, $primary, 'ADD INDEX', __('An index has been added on %s.'), 'Index', $titles, $row, false);
    if (!PMA_DRIZZLE) {
        $spatial_types = array('geometry', 'point', 'linestring', 'polygon', 'multipoint', 'multilinestring', 'multipolygon', 'geomtrycollection');
        $html_output .= PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'spatial nowrap', !in_array($type, $spatial_types) || 'MYISAM' != $tbl_storage_engine, false, $url_query, $primary, 'ADD SPATIAL', __('An index has been added on %s.'), 'Spatial', $titles, $row, false);
        // FULLTEXT is possible on TEXT, CHAR and VARCHAR
        $html_output .= PMA_getHtmlForFullTextAction($tbl_storage_engine, $type, $url_query, $row, $titles);
    }
    $html_output .= PMA_getHtmlForDistinctValueAction($url_query, $row, $titles);
    $html_output .= '<div class="clearfloat"></div></ul></td>';
    return $html_output;
}
开发者ID:pombredanne,项目名称:ArcherSys,代码行数:32,代码来源:structure.lib.php

示例3: PMA_getHtmlForActionsInTableStructure

/**
 * Get HTML snippet for Actions in table structure
 *
 * @param string  $type                      column type
 * @param string  $tbl_storage_engine        table storage engine
 * @param boolean $primary                   primary if set, false otherwise
 * @param string  $field_name                column name
 * @param string  $url_query                 url query
 * @param array   $titles                    titles array
 * @param array   $row                       current row
 * @param string  $rownum                    row number
 * @param array   $hidden_titles             hedden titles
 * @param array   $columns_with_unique_index columns with unique index
 *
 * @return string $html_output;
 */
function PMA_getHtmlForActionsInTableStructure($type, $tbl_storage_engine, $primary, $field_name, $url_query, $titles, $row, $rownum, $hidden_titles, $columns_with_unique_index)
{
    $html_output = '';
    list($primary, $primary_enabled) = PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'primary replaced_by_more center', $primary && $primary->hasColumn($field_name), true, $url_query, $primary, 'ADD PRIMARY KEY', __('A primary key has been added on %s'), 'Primary', $titles, $row, true);
    $html_output .= $primary;
    list($unique, $unique_enabled) = PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'unique replaced_by_more center', isset($columns_with_unique_index[$field_name]), false, $url_query, $primary, 'ADD UNIQUE', __('An index has been added on %s'), 'Unique', $titles, $row, false);
    $html_output .= $unique;
    list($index, $index_enabled) = PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'index replaced_by_more center', false, false, $url_query, $primary, 'ADD INDEX', __('An index has been added on %s'), 'Index', $titles, $row, false);
    $html_output .= $index;
    if (!PMA_DRIZZLE) {
        $spatial_types = array('geometry', 'point', 'linestring', 'polygon', 'multipoint', 'multilinestring', 'multipolygon', 'geomtrycollection');
        list($spatial, $spatial_enabled) = PMA_getHtmlForActionRowInStructureTable($type, $tbl_storage_engine, 'spatial replaced_by_more center', !in_array($type, $spatial_types) || 'MYISAM' != $tbl_storage_engine, false, $url_query, $primary, 'ADD SPATIAL', __('An index has been added on %s'), 'Spatial', $titles, $row, false);
        $html_output .= $spatial;
        // FULLTEXT is possible on TEXT, CHAR and VARCHAR
        list($fulltext, $fulltext_enabled) = PMA_getHtmlForFullTextAction($tbl_storage_engine, $type, $url_query, $row, $titles);
        $html_output .= $fulltext;
    }
    $html_output .= PMA_getHtmlForDistinctValueAction($url_query, $row, $titles);
    if ($GLOBALS['cfg']['PropertiesIconic'] !== true && $GLOBALS['cfg']['HideStructureActions'] === true) {
        $html_output .= PMA_getHtmlForMoreOptionInTableStructure($rownum, $primary_enabled, $url_query, $row, $hidden_titles, $unique_enabled, $index_enabled, $fulltext_enabled, $spatial_enabled, $primary);
    }
    return $html_output;
}
开发者ID:nhodges,项目名称:phpmyadmin,代码行数:39,代码来源:structure.lib.php


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