PMA\libraries\DisplayResults::_setDisplayPartsForShow PHP Method

_setDisplayPartsForShow() private method

Defines the parts to display for a SHOW statement
private _setDisplayPartsForShow ( array $displayParts ) : array
$displayParts array the parts to display
return array $displayParts the modified display parts
    private function _setDisplayPartsForShow($displayParts)
    {
        preg_match('@^SHOW[[:space:]]+(VARIABLES|(FULL[[:space:]]+)?' . 'PROCESSLIST|STATUS|TABLE|GRANTS|CREATE|LOGS|DATABASES|FIELDS' . ')@i', $this->__get('sql_query'), $which);
        $bIsProcessList = isset($which[1]);
        if ($bIsProcessList) {
            $str = ' ' . strtoupper($which[1]);
            $bIsProcessList = $bIsProcessList && strpos($str, 'PROCESSLIST') > 0;
        }
        if ($bIsProcessList) {
            // no edit link
            $displayParts['edit_lnk'] = self::NO_EDIT_OR_DELETE;
            // "kill process" type edit link
            $displayParts['del_lnk'] = self::KILL_PROCESS;
        } else {
            // Default case -> no links
            // no edit link
            $displayParts['edit_lnk'] = self::NO_EDIT_OR_DELETE;
            // no delete link
            $displayParts['del_lnk'] = self::NO_EDIT_OR_DELETE;
        }
        // Other settings
        $displayParts['sort_lnk'] = (string) '0';
        $displayParts['nav_bar'] = (string) '0';
        $displayParts['bkm_form'] = (string) '1';
        $displayParts['text_btn'] = (string) '1';
        $displayParts['pview_lnk'] = (string) '1';
        return $displayParts;
    }
DisplayResults