Merge remote-tracking branch 'origin/master'
[phpmyadmin.git] / server_variables.php
blobb287777206d2138fd57636eb93ab55642cd56965
1 <?php
2 /* vim: set expandtab sw=4 ts=4 sts=4: */
3 /**
4 * Server variables
6 * @package PhpMyAdmin
7 */
9 require_once 'libraries/common.inc.php';
10 require_once 'libraries/server_variables.lib.php';
12 $response = PMA_Response::getInstance();
13 $header = $response->getHeader();
14 $scripts = $header->getScripts();
15 $scripts->addFile('server_variables.js');
17 /**
18 * Does the common work
20 require 'libraries/server_common.inc.php';
22 /**
23 * Array of documentation links
25 $variable_doc_links = PMA_getArrayForDocumentLinks();
27 /**
28 * Ajax request
31 if (isset($_REQUEST['ajax_request']) && $_REQUEST['ajax_request'] == true) {
32 if (isset($_REQUEST['type'])) {
33 if ($_REQUEST['type'] === 'getval') {
34 PMA_getAjaxReturnForGetVal($variable_doc_links);
35 } else if ($_REQUEST['type'] === 'setval') {
36 PMA_getAjaxReturnForSetVal($variable_doc_links);
38 exit;
42 /**
43 * Displays the sub-page heading
45 $doc_link = PMA_Util::showMySQLDocu('server_system_variables');
46 $response->addHtml(PMA_getHtmlForSubPageHeader('variables', $doc_link));
48 /**
49 * Link templates
51 $response->addHtml(PMA_getHtmlForLinkTemplates());
53 /**
54 * Displays the page
56 $response->addHtml(PMA_getHtmlForServerVariables($variable_doc_links));
58 exit;