2 /* vim: set expandtab sw=4 ts=4 sts=4: */
4 * display selection for relational field values
8 declare(strict_types
=1);
10 use PhpMyAdmin\BrowseForeigners
;
11 use PhpMyAdmin\Controllers\BrowseForeignersController
;
12 use PhpMyAdmin\DatabaseInterface
;
13 use PhpMyAdmin\Di\Container
;
14 use PhpMyAdmin\Relation
;
15 use PhpMyAdmin\Response
;
18 if (! defined('ROOT_PATH')) {
19 define('ROOT_PATH', __DIR__
. DIRECTORY_SEPARATOR
);
22 require_once ROOT_PATH
. 'libraries/common.inc.php';
24 Util
::checkParameters(['db', 'table', 'field'], true);
26 $container = Container
::getDefaultContainer();
27 $container->set(Response
::class, Response
::getInstance());
29 /** @var Response $response */
30 $response = $container->get(Response
::class);
32 /** @var DatabaseInterface $dbi */
33 $dbi = $container->get(DatabaseInterface
::class);
35 $controller = new BrowseForeignersController(
39 $GLOBALS['cfg']['LimitChars'],
40 $GLOBALS['cfg']['MaxRows'],
41 $GLOBALS['cfg']['RepeatCells'],
42 $GLOBALS['cfg']['ShowAll'],
43 $GLOBALS['pmaThemeImage']
48 $response->getFooter()->setMinimal();
49 $header = $response->getHeader();
50 $header->disableMenuAndConsole();
51 $header->setBodyId('body_browse_foreigners');
53 $response->addHTML($controller->index([
54 'db' => $_POST['db'] ??
null,
55 'table' => $_POST['table'] ??
null,
56 'field' => $_POST['field'] ??
null,
57 'fieldkey' => $_POST['fieldkey'] ??
null,
58 'data' => $_POST['data'] ??
null,
59 'foreign_showAll' => $_POST['foreign_showAll'] ??
null,
60 'foreign_filter' => $_POST['foreign_filter'] ??
null,