Merge pull request #13411 from mauriciofauth/classes
Move classes to PhpMyAdmin namespace
This commit is contained in:
commit
ed6353d304
@ -22,7 +22,8 @@
|
||||
"non-feature-branches": ["RELEASE_.*"],
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"PMA\\": "./"
|
||||
"PMA\\": "./",
|
||||
"PhpMyAdmin\\": "libraries/classes"
|
||||
}
|
||||
},
|
||||
"repositories": [
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
|
||||
@ -201,8 +201,8 @@ foreach ($tables as $table) {
|
||||
$count++;
|
||||
echo '</table>';
|
||||
// display indexes information
|
||||
if (count(PMA\libraries\Index::getFromTable($table, $db)) > 0) {
|
||||
echo PMA\libraries\Index::getHtmlForIndexes($table, $db, true);
|
||||
if (count(PhpMyAdmin\Index::getFromTable($table, $db)) > 0) {
|
||||
echo PhpMyAdmin\Index::getHtmlForIndexes($table, $db, true);
|
||||
}
|
||||
echo '</div>';
|
||||
} //ends main while
|
||||
|
||||
@ -303,6 +303,6 @@ if ($cfgRelation['pdfwork'] && $num_tables > 0) {
|
||||
$test_rs = PMA_queryAsControlUser(
|
||||
$test_query,
|
||||
false,
|
||||
PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
} // end if
|
||||
|
||||
@ -131,7 +131,7 @@ if ($message_to_display) {
|
||||
unset($message_to_display);
|
||||
|
||||
// create new qbe search instance
|
||||
$db_qbe = new PMA\libraries\DbQbe($GLOBALS['db'], $savedSearchList, $savedSearch);
|
||||
$db_qbe = new PhpMyAdmin\DbQbe($GLOBALS['db'], $savedSearchList, $savedSearch);
|
||||
|
||||
$url = 'db_designer.php' . URL::getCommon(
|
||||
array_merge(
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
require_once 'libraries/common.inc.php';
|
||||
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\DbSearch;
|
||||
use PhpMyAdmin\DbSearch;
|
||||
|
||||
$response = Response::getInstance();
|
||||
$header = $response->getHeader();
|
||||
|
||||
@ -6,8 +6,8 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Encoding;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Encoding;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Sanitize;
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\gis\GISFactory;
|
||||
use PMA\libraries\gis\GISVisualization;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
10
import.php
10
import.php
@ -6,10 +6,10 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Bookmark;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Encoding;
|
||||
use PMA\libraries\File;
|
||||
use PhpMyAdmin\Bookmark;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Encoding;
|
||||
use PhpMyAdmin\File;
|
||||
use PMA\libraries\plugins\ImportPlugin;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Sql;
|
||||
@ -43,7 +43,7 @@ $response = Response::getInstance();
|
||||
// If it's a refresh console bookmarks request
|
||||
if (isset($_REQUEST['console_bookmark_refresh'])) {
|
||||
$response->addJSON(
|
||||
'console_message_bookmark', PMA\libraries\Console::getBookmarkContent()
|
||||
'console_message_bookmark', PhpMyAdmin\Console::getBookmarkContent()
|
||||
);
|
||||
exit;
|
||||
}
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
|
||||
/* PHP 5.4 stores upload progress data only in the default session.
|
||||
* After calling session_name(), we won't find the progress data anymore.
|
||||
|
||||
@ -6,9 +6,9 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Charsets;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\LanguageManager;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\LanguageManager;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\RecentFavoriteTable;
|
||||
use PMA\libraries\Response;
|
||||
@ -263,7 +263,7 @@ if ($GLOBALS['cfg']['ThemeManager']) {
|
||||
echo '</li>';
|
||||
}
|
||||
echo '<li id="li_select_fontsize">';
|
||||
echo PMA\libraries\Config::getFontsizeForm();
|
||||
echo PhpMyAdmin\Config::getFontsizeForm();
|
||||
echo '</li>';
|
||||
|
||||
echo '</ul>';
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
|
||||
/**
|
||||
* Misc logging functions
|
||||
|
||||
@ -7,6 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
/**
|
||||
@ -655,4 +656,3 @@ class Menu
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use TCPDF;
|
||||
use TCPDF_FONTS;
|
||||
|
||||
|
||||
@ -7,7 +7,9 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Footer;
|
||||
use PhpMyAdmin\Header;
|
||||
|
||||
/**
|
||||
* Singleton class used to manage the rendering of pages in PMA
|
||||
@ -47,7 +49,7 @@ class Response
|
||||
*/
|
||||
private $_JSON;
|
||||
/**
|
||||
* PMA\libraries\Footer instance
|
||||
* PhpMyAdmin\Footer instance
|
||||
*
|
||||
* @access private
|
||||
* @var Footer
|
||||
@ -182,7 +184,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a PMA\libraries\Header object
|
||||
* Returns a PhpMyAdmin\Header object
|
||||
*
|
||||
* @return Header
|
||||
*/
|
||||
@ -192,7 +194,7 @@ class Response
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a PMA\libraries\Footer object
|
||||
* Returns a PhpMyAdmin\Footer object
|
||||
*
|
||||
* @return Footer
|
||||
*/
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
|
||||
@ -7,6 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PhpMyAdmin\Header;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Sanitize;
|
||||
|
||||
|
||||
@ -11,11 +11,11 @@ use PhpMyAdmin\SqlParser\Statements\AlterStatement;
|
||||
use PhpMyAdmin\SqlParser\Statements\DropStatement;
|
||||
use PhpMyAdmin\SqlParser\Statements\SelectStatement;
|
||||
use PhpMyAdmin\SqlParser\Utils\Query;
|
||||
use PMA\libraries\Bookmark;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PMA\libraries\DisplayResults;
|
||||
use PMA\libraries\Index;
|
||||
use PhpMyAdmin\Bookmark;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PhpMyAdmin\DisplayResults;
|
||||
use PhpMyAdmin\Index;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Table;
|
||||
|
||||
@ -7,6 +7,8 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
|
||||
require_once 'libraries/database_interface.inc.php';
|
||||
|
||||
/**
|
||||
|
||||
@ -7,6 +7,8 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PhpMyAdmin\Index;
|
||||
use PMA\libraries\plugins\export\ExportSql;
|
||||
use PhpMyAdmin\SqlParser\Components\Expression;
|
||||
use PhpMyAdmin\SqlParser\Components\OptionsArray;
|
||||
|
||||
@ -17,7 +17,7 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
|
||||
@ -7,13 +7,14 @@
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ImportPlugin;
|
||||
use PhpMyAdmin\SqlParser\Context;
|
||||
use PhpMyAdmin\SqlParser\Lexer;
|
||||
use PhpMyAdmin\SqlParser\Parser;
|
||||
use PhpMyAdmin\SqlParser\Token;
|
||||
use stdClass;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Sanitize;
|
||||
use PMA\libraries\Template;
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
use PMA\libraries\Charsets;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
@ -6,11 +6,12 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use Exception;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
use Symfony\Component\ExpressionLanguage\ExpressionLanguage;
|
||||
|
||||
/**
|
||||
@ -5,10 +5,10 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
|
||||
/**
|
||||
* Handles bookmarking SQL queries
|
||||
@ -5,7 +5,8 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
@ -5,12 +5,15 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use DirectoryIterator;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\URL;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Error;
|
||||
use PhpMyAdmin\LanguageManager;
|
||||
use PMA\libraries\ThemeManager;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
* Indication for error handler (see end of this file).
|
||||
@ -88,7 +91,7 @@ class Config
|
||||
$this->settings = array();
|
||||
|
||||
// functions need to refresh in case of config file changed goes in
|
||||
// PMA\libraries\Config::load()
|
||||
// PhpMyAdmin\Config::load()
|
||||
$this->load($source);
|
||||
|
||||
// other settings, independent from config file, comes in
|
||||
@ -1794,5 +1797,5 @@ class Config
|
||||
}
|
||||
|
||||
if (!defined('TESTSUITE')) {
|
||||
register_shutdown_function(array('PMA\libraries\Config', 'fatalErrorHandler'));
|
||||
register_shutdown_function(array('PhpMyAdmin\Config', 'fatalErrorHandler'));
|
||||
}
|
||||
@ -5,10 +5,11 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\Bookmark;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\Bookmark;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
if (! defined('PHPMYADMIN')) {
|
||||
exit;
|
||||
@ -7,9 +7,9 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Sanitize;
|
||||
@ -5,12 +5,18 @@
|
||||
*
|
||||
* @package PhpMyAdmin-DBI
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\dbi\DBIExtension;
|
||||
use PMA\libraries\LanguageManager;
|
||||
use PhpMyAdmin\Error;
|
||||
use PhpMyAdmin\Index;
|
||||
use PhpMyAdmin\LanguageManager;
|
||||
use PMA\libraries\SystemDatabase;
|
||||
use PMA\libraries\Table;
|
||||
use PMA\libraries\Tracker;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
require_once './libraries/util.lib.php';
|
||||
|
||||
@ -917,7 +923,7 @@ class DatabaseInterface
|
||||
$GLOBALS['callback_sort_by'] = $sort_by;
|
||||
usort(
|
||||
$databases,
|
||||
array('PMA\libraries\DatabaseInterface', '_usortComparisonCallback')
|
||||
array(self::class, '_usortComparisonCallback')
|
||||
);
|
||||
unset($GLOBALS['callback_sort_order'], $GLOBALS['callback_sort_by']);
|
||||
|
||||
@ -1391,7 +1397,7 @@ class DatabaseInterface
|
||||
}
|
||||
}
|
||||
|
||||
if (PMA_MYSQL_INT_VERSION > 50503) {
|
||||
if (PMA_MYSQL_INT_VERSION > 50503) {
|
||||
$default_charset = 'utf8mb4';
|
||||
$default_collation = 'utf8mb4_general_ci';
|
||||
} else {
|
||||
@ -6,7 +6,9 @@
|
||||
* @package PhpMyAdmin
|
||||
*
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\ListDatabase;
|
||||
|
||||
/**
|
||||
* holds the DbList class
|
||||
@ -5,9 +5,11 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\Table;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
@ -5,9 +5,10 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\Sanitize;
|
||||
|
||||
/**
|
||||
@ -1,19 +1,26 @@
|
||||
<?php
|
||||
/* vim: set expandtab sw=4 ts=4 sts=4: */
|
||||
/**
|
||||
* Hold the PMA\libraries\DisplayResults class
|
||||
* Hold the PhpMyAdmin\DisplayResults class
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\SqlParser\Utils\Query;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PhpMyAdmin\Index;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\plugins\transformations\Text_Plain_Link;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Sanitize;
|
||||
use PMA\libraries\Sql;
|
||||
use PMA\libraries\Table;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\Transformations;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
* Handle all the functionalities related to displaying results
|
||||
@ -3055,7 +3062,7 @@ class DisplayResults
|
||||
$plugin_manager
|
||||
);
|
||||
|
||||
$transform_options = Transformations::getOptions(
|
||||
$transform_options = Transformations::getOptions(
|
||||
isset(
|
||||
$mime_map[$orgFullColName]
|
||||
['transformation_options']
|
||||
@ -3088,7 +3095,7 @@ class DisplayResults
|
||||
$transformation_plugin = new $this->transformation_info
|
||||
[$dbLower][$tblLower][$nameLower][1](null);
|
||||
|
||||
$transform_options = Transformations::getOptions(
|
||||
$transform_options = Transformations::getOptions(
|
||||
isset($mime_map[$orgFullColName]['transformation_options'])
|
||||
? $mime_map[$orgFullColName]['transformation_options']
|
||||
: ''
|
||||
@ -1,13 +1,13 @@
|
||||
<?php
|
||||
/* vim: set expandtab sw=4 ts=4 sts=4: */
|
||||
/**
|
||||
* Hold the PMA\libraries\Encoding class
|
||||
* Hold the PhpMyAdmin\Encoding class
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\config\ConfigFile;
|
||||
|
||||
/**
|
||||
@ -1,13 +1,14 @@
|
||||
<?php
|
||||
/* vim: set expandtab sw=4 ts=4 sts=4: */
|
||||
/**
|
||||
* Holds class PMA\libraries\Error
|
||||
* Holds class PhpMyAdmin\Error
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use Exception;
|
||||
use PMA\libraries\Message;
|
||||
|
||||
/**
|
||||
* a single error
|
||||
@ -164,7 +165,7 @@ class Error extends Message
|
||||
}
|
||||
|
||||
/**
|
||||
* sets PMA\libraries\Error::$_backtrace
|
||||
* sets PhpMyAdmin\Error::$_backtrace
|
||||
*
|
||||
* We don't store full arguments to avoid wakeup or memory problems.
|
||||
*
|
||||
@ -178,7 +179,7 @@ class Error extends Message
|
||||
}
|
||||
|
||||
/**
|
||||
* sets PMA\libraries\Error::$_line
|
||||
* sets PhpMyAdmin\Error::$_line
|
||||
*
|
||||
* @param integer $line the line
|
||||
*
|
||||
@ -190,7 +191,7 @@ class Error extends Message
|
||||
}
|
||||
|
||||
/**
|
||||
* sets PMA\libraries\Error::$_file
|
||||
* sets PhpMyAdmin\Error::$_file
|
||||
*
|
||||
* @param string $file the file
|
||||
*
|
||||
@ -203,9 +204,9 @@ class Error extends Message
|
||||
|
||||
|
||||
/**
|
||||
* returns unique PMA\libraries\Error::$hash, if not exists it will be created
|
||||
* returns unique PhpMyAdmin\Error::$hash, if not exists it will be created
|
||||
*
|
||||
* @return string PMA\libraries\Error::$hash
|
||||
* @return string PhpMyAdmin\Error::$hash
|
||||
*/
|
||||
public function getHash()
|
||||
{
|
||||
@ -228,13 +229,13 @@ class Error extends Message
|
||||
}
|
||||
|
||||
/**
|
||||
* returns PMA\libraries\Error::$_backtrace for first $count frames
|
||||
* returns PhpMyAdmin\Error::$_backtrace for first $count frames
|
||||
* pass $count = -1 to get full backtrace.
|
||||
* The same can be done by not passing $count at all.
|
||||
*
|
||||
* @param integer $count Number of stack frames.
|
||||
*
|
||||
* @return array PMA\libraries\Error::$_backtrace
|
||||
* @return array PhpMyAdmin\Error::$_backtrace
|
||||
*/
|
||||
public function getBacktrace($count = -1)
|
||||
{
|
||||
@ -245,9 +246,9 @@ class Error extends Message
|
||||
}
|
||||
|
||||
/**
|
||||
* returns PMA\libraries\Error::$file
|
||||
* returns PhpMyAdmin\Error::$file
|
||||
*
|
||||
* @return string PMA\libraries\Error::$file
|
||||
* @return string PhpMyAdmin\Error::$file
|
||||
*/
|
||||
public function getFile()
|
||||
{
|
||||
@ -255,9 +256,9 @@ class Error extends Message
|
||||
}
|
||||
|
||||
/**
|
||||
* returns PMA\libraries\Error::$line
|
||||
* returns PhpMyAdmin\Error::$line
|
||||
*
|
||||
* @return integer PMA\libraries\Error::$line
|
||||
* @return integer PhpMyAdmin\Error::$line
|
||||
*/
|
||||
public function getLine()
|
||||
{
|
||||
@ -483,7 +484,7 @@ class Error extends Message
|
||||
|
||||
$Ahere = explode(
|
||||
DIRECTORY_SEPARATOR,
|
||||
realpath(__DIR__ . DIRECTORY_SEPARATOR . '..')
|
||||
realpath(__DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..')
|
||||
);
|
||||
$Adest = explode(DIRECTORY_SEPARATOR, $dest);
|
||||
|
||||
@ -492,7 +493,7 @@ class Error extends Message
|
||||
while (implode(DIRECTORY_SEPARATOR, $Adest) != implode(DIRECTORY_SEPARATOR, $Ahere)) {
|
||||
if (count($Ahere) > count($Adest)) {
|
||||
array_pop($Ahere);
|
||||
$result .= DIRECTORY_SEPARATOR . '..';
|
||||
$result .= DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . '..';
|
||||
} else {
|
||||
array_pop($Adest);
|
||||
}
|
||||
@ -1,13 +1,15 @@
|
||||
<?php
|
||||
/* vim: set expandtab sw=4 ts=4 sts=4: */
|
||||
/**
|
||||
* Holds class PMA\libraries\ErrorHandler
|
||||
* Holds class PhpMyAdmin\ErrorHandler
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Error;
|
||||
use PhpMyAdmin\Error;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
/**
|
||||
* handling errors
|
||||
@ -3,13 +3,15 @@
|
||||
/**
|
||||
* file upload functions
|
||||
*
|
||||
* @package PMA\libraries
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\config\ConfigFile;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\ZipExtension;
|
||||
use PMA\libraries\Core;
|
||||
|
||||
/**
|
||||
* File wrapper class
|
||||
@ -17,7 +19,7 @@ use PMA\libraries\Core;
|
||||
* @todo when uploading a file into a blob field, should we also consider using
|
||||
* chunks like in import? UPDATE `table` SET `field` = `field` + [chunk]
|
||||
*
|
||||
* @package PMA\libraries
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
class File
|
||||
{
|
||||
@ -5,7 +5,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
/**
|
||||
* Class with Font related methods.
|
||||
@ -5,13 +5,17 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use Traversable;
|
||||
use PMA\libraries\URL;
|
||||
use PhpMyAdmin\Config;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Sanitize;
|
||||
use PMA\libraries\Config;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Scripts;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
use Traversable;
|
||||
|
||||
/**
|
||||
* Class used to output the footer
|
||||
@ -5,13 +5,19 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\Config;
|
||||
use PhpMyAdmin\Console;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Menu;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\navigation\Navigation;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\RecentFavoriteTable;
|
||||
use PMA\libraries\Sanitize;
|
||||
use PMA\libraries\Config;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Scripts;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
* Class used to output the HTTP and HTML headers
|
||||
@ -28,7 +34,7 @@ class Header
|
||||
*/
|
||||
private $_scripts;
|
||||
/**
|
||||
* PMA\libraries\Console instance
|
||||
* PhpMyAdmin\Console instance
|
||||
*
|
||||
* @access private
|
||||
* @var Console
|
||||
@ -126,7 +132,7 @@ class Header
|
||||
$this->_menuEnabled = true;
|
||||
$this->_warningsEnabled = true;
|
||||
$this->_isPrintView = false;
|
||||
$this->_scripts = new Scripts();
|
||||
$this->_scripts = new Scripts();
|
||||
$this->_addDefaultScripts();
|
||||
$this->_headerIsSent = false;
|
||||
// if database storage for user preferences is transient,
|
||||
@ -5,10 +5,13 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\URL;
|
||||
use PhpMyAdmin\IndexColumn;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Sanitize;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
* Index manipulation class
|
||||
@ -5,7 +5,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
/**
|
||||
* Index column wrapper
|
||||
@ -1,14 +1,13 @@
|
||||
<?php
|
||||
/* vim: set expandtab sw=4 ts=4 sts=4: */
|
||||
/**
|
||||
* Hold the PMA\libraries\LanguageManager class
|
||||
* Hold the PhpMyAdmin\Language class
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
|
||||
use PMA\libraries\LanguageManager;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\LanguageManager;
|
||||
|
||||
/**
|
||||
* Language object
|
||||
@ -1,15 +1,17 @@
|
||||
<?php
|
||||
/* vim: set expandtab sw=4 ts=4 sts=4: */
|
||||
/**
|
||||
* Hold the PMA\libraries\LanguageManager class
|
||||
* Hold the PhpMyAdmin\LanguageManager class
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Language;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Language;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
* Language selection manager
|
||||
@ -5,7 +5,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\SqlParser\Lexer;
|
||||
use PhpMyAdmin\SqlParser\Parser;
|
||||
@ -19,7 +19,6 @@ use PhpMyAdmin\SqlParser\Utils\Error as ParserError;
|
||||
*/
|
||||
class Linter
|
||||
{
|
||||
|
||||
/**
|
||||
* Gets the starting position of each line.
|
||||
*
|
||||
@ -5,7 +5,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use ArrayObject;
|
||||
|
||||
@ -5,7 +5,10 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
namespace PMA\libraries;
|
||||
namespace PhpMyAdmin;
|
||||
|
||||
use PhpMyAdmin\ListAbstract;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
require_once './libraries/check_user_privileges.lib.php';
|
||||
|
||||
@ -31,19 +31,19 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Config;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PMA\libraries\ErrorHandler;
|
||||
use PhpMyAdmin\Config;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PhpMyAdmin\ErrorHandler;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\plugins\AuthenticationPlugin;
|
||||
use PMA\libraries\DbList;
|
||||
use PhpMyAdmin\DbList;
|
||||
use PMA\libraries\ThemeManager;
|
||||
use PMA\libraries\Tracker;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\TypesMySQL;
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\LanguageManager;
|
||||
use PhpMyAdmin\LanguageManager;
|
||||
use PMA\libraries\Logging;
|
||||
|
||||
/**
|
||||
@ -361,14 +361,14 @@ if (Core::checkPageValidity($_REQUEST['back'], $goto_whitelist)) {
|
||||
*
|
||||
* remember that some objects in the session with session_start and __wakeup()
|
||||
* could access this variables before we reach this point
|
||||
* f.e. PMA\libraries\Config: fontsize
|
||||
* f.e. PhpMyAdmin\Config: fontsize
|
||||
*
|
||||
* Check for token mismatch only if the Request method is POST
|
||||
* GET Requests would never have token and therefore checking
|
||||
* mis-match does not make sense
|
||||
*
|
||||
* @todo variables should be handled by their respective owners (objects)
|
||||
* f.e. lang, server, collation_connection in PMA\libraries\Config
|
||||
* f.e. lang, server, collation_connection in PhpMyAdmin\Config
|
||||
*/
|
||||
|
||||
$token_mismatch = true;
|
||||
@ -487,8 +487,8 @@ $GLOBALS['server'] = 0;
|
||||
|
||||
/**
|
||||
* Servers array fixups.
|
||||
* $default_server comes from PMA\libraries\Config::enableBc()
|
||||
* @todo merge into PMA\libraries\Config
|
||||
* $default_server comes from PhpMyAdmin\Config::enableBc()
|
||||
* @todo merge into PhpMyAdmin\Config
|
||||
*/
|
||||
// Do we have some server?
|
||||
if (! isset($cfg['Servers']) || count($cfg['Servers']) == 0) {
|
||||
@ -590,7 +590,7 @@ if (! defined('PMA_MINIMUM_COMMON')) {
|
||||
|
||||
/**
|
||||
* save some settings in cookies
|
||||
* @todo should be done in PMA\libraries\Config
|
||||
* @todo should be done in PhpMyAdmin\Config
|
||||
*/
|
||||
$GLOBALS['PMA_Config']->setCookie('pma_lang', $GLOBALS['lang']);
|
||||
if (isset($GLOBALS['collation_connection'])) {
|
||||
@ -612,7 +612,7 @@ if (! defined('PMA_MINIMUM_COMMON')) {
|
||||
// get LoginCookieValidity from preferences cache
|
||||
// no generic solution for loading preferences from cache as some settings
|
||||
// need to be kept for processing in
|
||||
// PMA\libraries\Config::loadUserPreferences()
|
||||
// PhpMyAdmin\Config::loadUserPreferences()
|
||||
$cache_key = 'server_' . $GLOBALS['server'];
|
||||
if (isset($_SESSION['cache'][$cache_key]['userprefs']['LoginCookieValidity'])
|
||||
) {
|
||||
|
||||
@ -7,8 +7,8 @@
|
||||
*/
|
||||
namespace PMA\libraries\config;
|
||||
|
||||
use PMA\libraries\Config;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Config;
|
||||
use PhpMyAdmin\Core;
|
||||
|
||||
/**
|
||||
* Config file management class.
|
||||
@ -78,7 +78,7 @@ class ConfigFile
|
||||
* Constructor
|
||||
*
|
||||
* @param array $base_config base configuration read from
|
||||
* {@link PMA\libraries\Config::$base_config},
|
||||
* {@link PhpMyAdmin\Config::$base_config},
|
||||
* use only when not in PMA Setup
|
||||
*/
|
||||
public function __construct(array $base_config = null)
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\config;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\config;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\URL;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
|
||||
@ -7,8 +7,8 @@
|
||||
*/
|
||||
namespace PMA\libraries\config;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
/**
|
||||
@ -49,7 +49,7 @@ class Validator
|
||||
|
||||
// not in setup script: load additional validators for user
|
||||
// preferences we need original config values not overwritten
|
||||
// by user preferences, creating a new PMA\libraries\Config instance is a
|
||||
// by user preferences, creating a new PhpMyAdmin\Config instance is a
|
||||
// better idea than hacking into its code
|
||||
$uvs = $cf->getDbEntry('_userValidators', array());
|
||||
foreach ($uvs as $field => $uv_list) {
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\controllers;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\di\Container;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
|
||||
@ -11,8 +11,8 @@ namespace PMA\libraries\controllers\database;
|
||||
|
||||
use PMA\libraries\config\PageSettings;
|
||||
use PMA\libraries\controllers\DatabaseController;
|
||||
use PMA\libraries\Charsets;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\RecentFavoriteTable;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
namespace PMA\libraries\controllers\server;
|
||||
|
||||
use PMA\libraries\controllers\Controller;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\Template;
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
namespace PMA\libraries\controllers\server;
|
||||
|
||||
use PMA\libraries\controllers\Controller;
|
||||
use PMA\libraries\Charsets;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PMA\libraries\Template;
|
||||
|
||||
/**
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
namespace PMA\libraries\controllers\server;
|
||||
|
||||
use PMA\libraries\controllers\Controller;
|
||||
use PMA\libraries\Charsets;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Template;
|
||||
@ -336,7 +336,7 @@ class ServerDatabasesController extends Controller
|
||||
$column_order = array();
|
||||
$column_order['DEFAULT_COLLATION_NAME'] = array(
|
||||
'disp_name' => __('Collation'),
|
||||
'description_function' => array('\PMA\libraries\Charsets', 'getCollationDescr'),
|
||||
'description_function' => array(Charsets::class, 'getCollationDescr'),
|
||||
'format' => 'string',
|
||||
'footer' => $this->dbi->getServerCollation(),
|
||||
);
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
namespace PMA\libraries\controllers\table;
|
||||
|
||||
use PMA\libraries\controllers\TableController;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\gis\GISVisualization;
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
namespace PMA\libraries\controllers\table;
|
||||
|
||||
use PMA\libraries\controllers\TableController;
|
||||
use PMA\libraries\Index;
|
||||
use PhpMyAdmin\Index;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
@ -9,9 +9,9 @@
|
||||
namespace PMA\libraries\controllers\table;
|
||||
|
||||
use PMA\libraries\controllers\TableController;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PMA\libraries\Index;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PhpMyAdmin\Index;
|
||||
use PMA\libraries\Table;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
namespace PMA\libraries\controllers\table;
|
||||
|
||||
use PMA\libraries\controllers\TableController;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\Sql;
|
||||
use PMA\libraries\Template;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
@ -14,8 +14,8 @@ use PhpMyAdmin\SqlParser\Statements\CreateStatement;
|
||||
use PhpMyAdmin\SqlParser\Utils\Table as SqlTable;
|
||||
use PMA\libraries\config\PageSettings;
|
||||
use PMA\libraries\controllers\TableController;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Index;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Index;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Sql;
|
||||
use PMA\libraries\Table;
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Table;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
@ -176,7 +176,7 @@ function PMA_buildIndexStatements($index, $index_choice,
|
||||
$type = $index['Index_type'];
|
||||
if ($index['Index_choice'] != 'SPATIAL'
|
||||
&& $index['Index_choice'] != 'FULLTEXT'
|
||||
&& in_array($type, PMA\libraries\Index::getIndexTypes())
|
||||
&& in_array($type, PhpMyAdmin\Index::getIndexTypes())
|
||||
) {
|
||||
$sql_query .= ' USING ' . $type;
|
||||
}
|
||||
|
||||
@ -7,10 +7,10 @@
|
||||
* @package PhpMyAdmin-DBI
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\dbi\DBIDummy;
|
||||
use PMA\libraries\di\Container;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\dbi\DBIMysql;
|
||||
use PMA\libraries\dbi\DBIMysqli;
|
||||
|
||||
@ -42,7 +42,7 @@ if (defined('TESTSUITE')) {
|
||||
|
||||
if (PHP_VERSION_ID < 70000) {
|
||||
$extension = 'mysql';
|
||||
if (! PMA\libraries\DatabaseInterface::checkDbExtension($extension)) {
|
||||
if (! PhpMyAdmin\DatabaseInterface::checkDbExtension($extension)) {
|
||||
// warn about both extensions missing and exit
|
||||
Core::warnMissingExtension(
|
||||
'mysqli',
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
@ -85,7 +85,7 @@ function PMA_getPageIdsAndNames($db)
|
||||
. " WHERE db_name = '" . $GLOBALS['dbi']->escapeString($db) . "'"
|
||||
. " ORDER BY `page_descr`";
|
||||
$page_rs = PMA_queryAsControlUser(
|
||||
$page_query, false, PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
$page_query, false, PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
|
||||
$result = array();
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\URL;
|
||||
@ -67,7 +67,7 @@ if (empty($is_table)
|
||||
$_result = $GLOBALS['dbi']->tryQuery(
|
||||
'SHOW TABLES LIKE \''
|
||||
. $GLOBALS['dbi']->escapeString($table) . '\';',
|
||||
null, PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
null, PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
$is_table = @$GLOBALS['dbi']->numRows($_result);
|
||||
$GLOBALS['dbi']->freeResult($_result);
|
||||
@ -91,7 +91,7 @@ if (empty($is_table)
|
||||
'SELECT COUNT(*) FROM ' . PMA\libraries\Util::backquote($table)
|
||||
. ';',
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
$is_table = ($_result && @$GLOBALS['dbi']->numRows($_result));
|
||||
$GLOBALS['dbi']->freeResult($_result);
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\dbi;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
|
||||
if (! defined('PHPMYADMIN')) {
|
||||
exit;
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\dbi;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
|
||||
if (! defined('PHPMYADMIN')) {
|
||||
exit;
|
||||
|
||||
@ -7,8 +7,8 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Encoding;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Encoding;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Response;
|
||||
|
||||
/**
|
||||
|
||||
@ -9,9 +9,9 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Charsets;
|
||||
use PMA\libraries\Core;
|
||||
use PMA\libraries\Encoding;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PhpMyAdmin\Core;
|
||||
use PhpMyAdmin\Encoding;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\plugins\ImportPlugin;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
|
||||
/**
|
||||
* Sets up some variables for upload progress
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
namespace PMA\libraries\engines;
|
||||
|
||||
use PMA;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\StorageEngine;
|
||||
|
||||
/**
|
||||
|
||||
@ -92,7 +92,7 @@ function PMA_getReportData($exception_type = 'js')
|
||||
return array();
|
||||
}
|
||||
foreach ($_SESSION['prev_errors'] as $errorObj) {
|
||||
/* @var $errorObj PMA\libraries\Error */
|
||||
/* @var $errorObj PhpMyAdmin\Error */
|
||||
if ($errorObj->getLine()
|
||||
&& $errorObj->getType()
|
||||
&& $errorObj->getNumber() != E_USER_WARNING
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
use PMA\libraries\Encoding;
|
||||
use PhpMyAdmin\Encoding;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\Table;
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
|
||||
namespace PMA\libraries\gis;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Util;
|
||||
use \TCPDF;
|
||||
use PMA\libraries\Sanitize;
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
*
|
||||
* @package PhpMyAdmin-Import
|
||||
*/
|
||||
use PMA\libraries\Encoding;
|
||||
use PhpMyAdmin\Encoding;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Table;
|
||||
|
||||
@ -87,7 +87,7 @@ function PMA_analyzeWhereClauses(
|
||||
. PMA\libraries\Util::backquote($table)
|
||||
. ' WHERE ' . $where_clause . ';';
|
||||
$result[$key_id] = $GLOBALS['dbi']->query(
|
||||
$local_query, null, PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
$local_query, null, PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
$rows[$key_id] = $GLOBALS['dbi']->fetchAssoc($result[$key_id]);
|
||||
|
||||
@ -167,7 +167,7 @@ function PMA_loadFirstRow($table, $db)
|
||||
'SELECT * FROM ' . PMA\libraries\Util::backquote($db)
|
||||
. '.' . PMA\libraries\Util::backquote($table) . ' LIMIT 1;',
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
$rows = array_fill(0, $GLOBALS['cfg']['InsertRows'], false);
|
||||
return array($result, $rows);
|
||||
@ -2091,7 +2091,7 @@ function PMA_getDisplayValueForForeignTableColumn($where_comparison,
|
||||
. ' WHERE ' . PMA\libraries\Util::backquote($foreigner['foreign_field'])
|
||||
. $where_comparison;
|
||||
$dispresult = $GLOBALS['dbi']->tryQuery(
|
||||
$dispsql, null, PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
$dispsql, null, PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
);
|
||||
if ($dispresult && $GLOBALS['dbi']->numRows($dispresult) > 0) {
|
||||
list($dispval) = $GLOBALS['dbi']->fetchRow($dispresult, 0);
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
require_once './libraries/hash.lib.php';
|
||||
|
||||
/**
|
||||
|
||||
@ -181,7 +181,7 @@ function PMA_getHtmlContentsFor1NFStep2($db, $table)
|
||||
{
|
||||
$step = 2;
|
||||
$stepTxt = __('Have a primary key');
|
||||
$primary = PMA\libraries\Index::getPrimary($table, $db);
|
||||
$primary = PhpMyAdmin\Index::getPrimary($table, $db);
|
||||
$hasPrimaryKey = "0";
|
||||
$legendText = __('Step 1.') . $step . " " . $stepTxt;
|
||||
$extra = '';
|
||||
@ -288,7 +288,7 @@ function PMA_getHtmlContentsFor1NFStep3($db, $table)
|
||||
. '<input type="submit" value="' . __('No repeating group')
|
||||
. '" onclick="goToStep4();"'
|
||||
. '/>';
|
||||
$primary = PMA\libraries\Index::getPrimary($table, $db);
|
||||
$primary = PhpMyAdmin\Index::getPrimary($table, $db);
|
||||
$primarycols = $primary->getColumns();
|
||||
$pk = array();
|
||||
foreach ($primarycols as $col) {
|
||||
@ -315,7 +315,7 @@ function PMA_getHtmlContentsFor1NFStep3($db, $table)
|
||||
function PMA_getHtmlFor2NFstep1($db, $table)
|
||||
{
|
||||
$legendText = __('Step 2.') . "1 " . __('Find partial dependencies');
|
||||
$primary = PMA\libraries\Index::getPrimary($table, $db);
|
||||
$primary = PhpMyAdmin\Index::getPrimary($table, $db);
|
||||
$primarycols = $primary->getColumns();
|
||||
$pk = array();
|
||||
$subText = '';
|
||||
@ -521,7 +521,7 @@ function PMA_getHtmlForNewTables3NF($dependencies, $tables, $db)
|
||||
if (count(array_unique($arrDependson)) == 1) {
|
||||
continue;
|
||||
}
|
||||
$primary = PMA\libraries\Index::getPrimary($table, $db);
|
||||
$primary = PhpMyAdmin\Index::getPrimary($table, $db);
|
||||
$primarycols = $primary->getColumns();
|
||||
$pk = array();
|
||||
foreach ($primarycols as $col) {
|
||||
@ -735,7 +735,7 @@ function PMA_getHtmlFor3NFstep1($db, $tables)
|
||||
);
|
||||
$cnt = 0;
|
||||
foreach ($tables as $table) {
|
||||
$primary = PMA\libraries\Index::getPrimary($table, $db);
|
||||
$primary = PhpMyAdmin\Index::getPrimary($table, $db);
|
||||
$primarycols = $primary->getColumns();
|
||||
$selectTdForm = "";
|
||||
$pk = array();
|
||||
@ -847,7 +847,7 @@ function PMA_findPartialDependencies($table, $db)
|
||||
. Util::backquote($table) . ' LIMIT 500) as dt;'
|
||||
);
|
||||
$totalRows = $totalRowsRes[0];
|
||||
$primary = PMA\libraries\Index::getPrimary($table, $db);
|
||||
$primary = PhpMyAdmin\Index::getPrimary($table, $db);
|
||||
$primarycols = $primary->getColumns();
|
||||
$pk = array();
|
||||
foreach ($primarycols as $col) {
|
||||
|
||||
@ -6,8 +6,8 @@
|
||||
* @package PhpMyAdmin
|
||||
*/
|
||||
use PMA\libraries\engines\Innodb;
|
||||
use PMA\libraries\Charsets;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Partition;
|
||||
use PMA\libraries\plugins\export\ExportSql;
|
||||
|
||||
@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\Sanitize;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
|
||||
@ -9,13 +9,13 @@
|
||||
namespace PMA\libraries\plugins\auth;
|
||||
|
||||
use phpseclib\Crypt;
|
||||
use PMA\libraries\LanguageManager;
|
||||
use PhpMyAdmin\LanguageManager;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\plugins\AuthenticationPlugin;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Util;
|
||||
use PMA\libraries\Config;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Config;
|
||||
use PhpMyAdmin\Core;
|
||||
use ReCaptcha;
|
||||
use PMA\libraries\URL;
|
||||
|
||||
|
||||
@ -12,8 +12,8 @@ namespace PMA\libraries\plugins\auth;
|
||||
use PMA\libraries\plugins\AuthenticationPlugin;
|
||||
use PMA\libraries\Message;
|
||||
use PMA\libraries\Response;
|
||||
use PMA\libraries\Config;
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Config;
|
||||
use PhpMyAdmin\Core;
|
||||
|
||||
require_once './libraries/hash.lib.php';
|
||||
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\auth;
|
||||
|
||||
use PMA\libraries\Core;
|
||||
use PhpMyAdmin\Core;
|
||||
use PMA\libraries\plugins\AuthenticationPlugin;
|
||||
use PMA;
|
||||
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\properties\options\items\BoolPropertyItem;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
@ -228,7 +229,7 @@ class ExportCsv extends ExportPlugin
|
||||
$result = $GLOBALS['dbi']->query(
|
||||
$sql_query,
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_UNBUFFERED
|
||||
DatabaseInterface::QUERY_UNBUFFERED
|
||||
);
|
||||
$fields_cnt = $GLOBALS['dbi']->numFields($result);
|
||||
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\properties\options\items\BoolPropertyItem;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
@ -236,7 +237,7 @@ class ExportJson extends ExportPlugin
|
||||
$result = $GLOBALS['dbi']->query(
|
||||
$sql_query,
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_UNBUFFERED
|
||||
DatabaseInterface::QUERY_UNBUFFERED
|
||||
);
|
||||
$columns_cnt = $GLOBALS['dbi']->numFields($result);
|
||||
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
|
||||
@ -8,6 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\properties\options\items\BoolPropertyItem;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
@ -329,7 +330,7 @@ class ExportMediawiki extends ExportPlugin
|
||||
$result = $GLOBALS['dbi']->query(
|
||||
$sql_query,
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_UNBUFFERED
|
||||
DatabaseInterface::QUERY_UNBUFFERED
|
||||
);
|
||||
$fields_cnt = $GLOBALS['dbi']->numFields($result);
|
||||
|
||||
|
||||
@ -14,7 +14,7 @@ use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\items\HiddenPropertyItem;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyRootGroup;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\properties\options\items\TextPropertyItem;
|
||||
use PMA\libraries\OpenDocument;
|
||||
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\items\HiddenPropertyItem;
|
||||
@ -181,7 +182,7 @@ class ExportPhparray extends ExportPlugin
|
||||
$result = $GLOBALS['dbi']->query(
|
||||
$sql_query,
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_UNBUFFERED
|
||||
DatabaseInterface::QUERY_UNBUFFERED
|
||||
);
|
||||
|
||||
$columns_cnt = $GLOBALS['dbi']->numFields($result);
|
||||
|
||||
@ -13,8 +13,8 @@ use PhpMyAdmin\SqlParser\Context;
|
||||
use PhpMyAdmin\SqlParser\Parser;
|
||||
use PhpMyAdmin\SqlParser\Statements\SelectStatement;
|
||||
use PhpMyAdmin\SqlParser\Token;
|
||||
use PMA\libraries\Charsets;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\Charsets;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
@ -1386,7 +1386,7 @@ class ExportSql extends ExportPlugin
|
||||
$compat = 'NONE';
|
||||
}
|
||||
|
||||
// need to use PMA\libraries\DatabaseInterface::QUERY_STORE
|
||||
// need to use PhpMyAdmin\DatabaseInterface::QUERY_STORE
|
||||
// with $GLOBALS['dbi']->numRows() in mysqli
|
||||
$result = $GLOBALS['dbi']->query(
|
||||
'SHOW TABLE STATUS FROM ' . Util::backquote($db)
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
|
||||
@ -13,7 +13,7 @@ use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\items\HiddenPropertyItem;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyMainGroup;
|
||||
use PMA\libraries\properties\options\groups\OptionsPropertyRootGroup;
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
|
||||
namespace PMA\libraries\plugins\export;
|
||||
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\plugins\ExportPlugin;
|
||||
use PMA\libraries\properties\plugins\ExportPluginProperties;
|
||||
use PMA\libraries\properties\options\items\HiddenPropertyItem;
|
||||
@ -157,7 +158,7 @@ class ExportYaml extends ExportPlugin
|
||||
$result = $GLOBALS['dbi']->query(
|
||||
$sql_query,
|
||||
null,
|
||||
PMA\libraries\DatabaseInterface::QUERY_UNBUFFERED
|
||||
DatabaseInterface::QUERY_UNBUFFERED
|
||||
);
|
||||
|
||||
$columns_cnt = $GLOBALS['dbi']->numFields($result);
|
||||
|
||||
@ -8,7 +8,7 @@
|
||||
*/
|
||||
namespace PMA\libraries\plugins\export\helpers;
|
||||
|
||||
use PMA\libraries\DatabaseInterface;
|
||||
use PhpMyAdmin\DatabaseInterface;
|
||||
use PMA\libraries\PDF as PdfLib;
|
||||
use PMA\libraries\Transformations;
|
||||
use PMA\libraries\Util;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user