#/** * @package Akismet */ /* Plugin Name: Akismet Anti-spam: Spam Protection Plugin URI: https://akismet.com/ Description: Used by millions, Akismet is quite possibly the best way in the world to protect your blog from spam. Akismet Anti-spam keeps your site protected even while you sleep. To get started: activate the Akismet plugin and then go to your Akismet Settings page to set up your API key. Version: 5.4 Requires at least: 5.8 Requires PHP: 7.2 Author: Automattic - Anti-spam Team Author URI: https://automattic.com/wordpress-plugins/ License: GPLv2 or later Text Domain: akismet */ /* This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. Copyright 2005-2025 Automattic, Inc. */ // Make sure we don't expose any info if called directly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
| Server IP : 62.109.13.187 / Your IP : 216.73.216.11 [ Web Server : Apache/2.4.6 (CentOS) mpm-itk/2.4.7-04 OpenSSL/1.0.2k-fips PHP/8.2.28 System : Linux robothost.ru 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64 User : mosrembit ( 6064) PHP Version : 8.2.28 Disable Function : NONE Domains : 0 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /usr/share/phpMyAdmin/libraries/ |
Upload File : |
<?php
/* vim: set expandtab sw=4 ts=4 sts=4: */
/**
* Gets the list of the table in the current db and information about these
* tables if possible
*
* fills tooltip arrays and provides $tables, $num_tables, $is_show_stats
* and $db_is_system_schema
*
* speedup view on locked tables
*
* @package PhpMyAdmin
*/
if (! defined('PHPMYADMIN')) {
exit;
}
/**
* limits for table list
*/
if (! isset($_SESSION['tmpval']['table_limit_offset'])
|| $_SESSION['tmpval']['table_limit_offset_db'] != $db
) {
$_SESSION['tmpval']['table_limit_offset'] = 0;
$_SESSION['tmpval']['table_limit_offset_db'] = $db;
}
if (isset($_REQUEST['pos'])) {
$_SESSION['tmpval']['table_limit_offset'] = (int) $_REQUEST['pos'];
}
$pos = $_SESSION['tmpval']['table_limit_offset'];
PMA_Util::checkParameters(array('db'));
/**
* @global bool whether to display extended stats
*/
$is_show_stats = $cfg['ShowStats'];
/**
* @global bool whether selected db is information_schema
*/
$db_is_system_schema = false;
if ($GLOBALS['dbi']->isSystemSchema($db)) {
$is_show_stats = false;
$db_is_system_schema = true;
}
/**
* @global array information about tables in db
*/
$tables = array();
$tooltip_truename = array();
$tooltip_aliasname = array();
// Special speedup for newer MySQL Versions (in 4.0 format changed)
if (true === $cfg['SkipLockedTables'] && ! PMA_DRIZZLE) {
$db_info_result = $GLOBALS['dbi']->query(
'SHOW OPEN TABLES FROM ' . PMA_Util::backquote($db) . ';'
);
// Blending out tables in use
if ($db_info_result && $GLOBALS['dbi']->numRows($db_info_result) > 0) {
while ($tmp = $GLOBALS['dbi']->fetchAssoc($db_info_result)) {
// if in use, memorize table name
if ($tmp['In_use'] > 0) {
$sot_cache[$tmp['Table']] = true;
}
}
$GLOBALS['dbi']->freeResult($db_info_result);
if (isset($sot_cache)) {
$db_info_result = false;
$tblGroupSql = "";
$whereAdded = false;
if (PMA_isValid($_REQUEST['tbl_group'])) {
$group = PMA_Util::escapeMysqlWildcards($_REQUEST['tbl_group']);
$groupWithSeparator = PMA_Util::escapeMysqlWildcards(
$_REQUEST['tbl_group']
. $GLOBALS['cfg']['NavigationTreeTableSeparator']
);
$tblGroupSql .= " WHERE ("
. PMA_Util::backquote('Tables_in_' . $db)
. " LIKE '" . $groupWithSeparator . "%'"
. " OR "
. PMA_Util::backquote('Tables_in_' . $db)
. " LIKE '" . $group . "')";
$whereAdded = true;
}
if (PMA_isValid($_REQUEST['tbl_type'], array('table', 'view'))) {
$tblGroupSql .= $whereAdded ? " AND" : " WHERE";
if ($_REQUEST['tbl_type'] == 'view') {
$tblGroupSql .= " `Table_type` != 'BASE TABLE'";
} else {
$tblGroupSql .= " `Table_type` = 'BASE TABLE'";
}
}
$db_info_result = $GLOBALS['dbi']->query(
'SHOW FULL TABLES FROM ' . PMA_Util::backquote($db) . $tblGroupSql,
null, PMA_DatabaseInterface::QUERY_STORE
);
unset($tblGroupSql, $whereAdded);
if ($db_info_result && $GLOBALS['dbi']->numRows($db_info_result) > 0) {
while ($tmp = $GLOBALS['dbi']->fetchRow($db_info_result)) {
if (! isset($sot_cache[$tmp[0]])) {
$sts_result = $GLOBALS['dbi']->query(
"SHOW TABLE STATUS FROM " . PMA_Util::backquote($db)
. " LIKE '" . PMA_Util::sqlAddSlashes($tmp[0], true)
. "';"
);
$sts_tmp = $GLOBALS['dbi']->fetchAssoc($sts_result);
$GLOBALS['dbi']->freeResult($sts_result);
unset($sts_result);
$tableArray = $GLOBALS['dbi']->copyTableProperties(
array($sts_tmp), $db
);
$tables[$sts_tmp['Name']] = $tableArray[0];
} else { // table in use
$tables[$tmp[0]] = array(
'TABLE_NAME' => $tmp[0],
'ENGINE' => '',
'TABLE_TYPE' => '',
'TABLE_ROWS' => 0,
);
}
}
if ($GLOBALS['cfg']['NaturalOrder']) {
uksort($tables, 'strnatcasecmp');
}
$sot_ready = true;
} elseif ($db_info_result) {
$GLOBALS['dbi']->freeResult($db_info_result);
}
unset($sot_cache);
}
unset($tmp);
} elseif ($db_info_result) {
$GLOBALS['dbi']->freeResult($db_info_result);
}
}
if (! isset($sot_ready)) {
// Set some sorting defaults
$sort = 'Name';
$sort_order = 'ASC';
if (isset($_REQUEST['sort'])) {
$sortable_name_mappings = array(
'table' => 'Name',
'records' => 'Rows',
'type' => 'Engine',
'collation' => 'Collation',
'size' => 'Data_length',
'overhead' => 'Data_free',
'creation' => 'Create_time',
'last_update' => 'Update_time',
'last_check' => 'Check_time'
);
// Make sure the sort type is implemented
if (isset($sortable_name_mappings[$_REQUEST['sort']])) {
$sort = $sortable_name_mappings[$_REQUEST['sort']];
if ($_REQUEST['sort_order'] == 'DESC') {
$sort_order = 'DESC';
}
}
}
$tbl_group = false;
$groupWithSeparator = false;
$tbl_type = null;
$limit_offset = 0;
$limit_count = false;
$groupTable = array();
if (! empty($_REQUEST['tbl_group']) || ! empty($_REQUEST['tbl_type'])) {
if (! empty($_REQUEST['tbl_type'])) {
// only tables for selected type
$tbl_type = $_REQUEST['tbl_type'];
}
if (! empty($_REQUEST['tbl_group'])) {
// only tables for selected group
$tbl_group = $_REQUEST['tbl_group'];
// include the table with the exact name of the group if such exists
$groupTable = $GLOBALS['dbi']->getTablesFull(
$db, $tbl_group, false, null, $limit_offset,
$limit_count, $sort, $sort_order, $tbl_type
);
$groupWithSeparator = $tbl_group
. $GLOBALS['cfg']['NavigationTreeTableSeparator'];
}
} else {
// all tables in db
// - get the total number of tables
// (needed for proper working of the MaxTableList feature)
$tables = $GLOBALS['dbi']->getTables($db);
$total_num_tables = count($tables);
if (isset($sub_part) && $sub_part == '_export') {
// (don't fetch only a subset if we are coming from db_export.php,
// because I think it's too risky to display only a subset of the
// table names when exporting a db)
/**
*
* @todo Page selector for table names?
*/
} else {
// fetch the details for a possible limited subset
$limit_offset = $pos;
$limit_count = true;
}
}
$tables = array_merge(
$groupTable,
$GLOBALS['dbi']->getTablesFull(
$db, $groupWithSeparator, ($groupWithSeparator != false), null,
$limit_offset, $limit_count, $sort, $sort_order, $tbl_type
)
);
}
/**
* @global int count of tables in db
*/
$num_tables = count($tables);
// (needed for proper working of the MaxTableList feature)
if (! isset($total_num_tables)) {
$total_num_tables = $num_tables;
}
/**
* cleanup
*/
unset($each_table, $db_info_result);
/**
* If coming from a Show MySQL link on the home page,
* put something in $sub_part
*/
if (empty($sub_part)) {
$sub_part = '_structure';
}
?>