phpMyAdmin resolution when accessing the structure options of a table

Source: Internet
Author: User

The first step is to open the./version_check.php file. Locate the following code.
$save = true; 
    $file = ‘http://www.phpmyadmin.net/home_page/version.json‘; 
    if (ini_get(‘allow_url_fopen‘)) { 
        $response = file_get_contents($file); 
    } else if (function_exists(‘curl_init‘)) { 
        $curl_handle = curl_init($file); 
        curl_setopt($curl_handle, CURLOPT_RETURNTRANSFER, 1); 
        $response = curl_exec($curl_handle); 
    }
Remove or comment out the above code. The reason is that the official hang up, this check upgrade takes 30 seconds. There is no need to check online for new versions.

The second step is to open the./libraries/util.class.php file.
Find
return strftime($date, $timestamp);
Replace with the following code:
if(extension_loaded(‘gettext‘)) 
  return strftime($date, $timestamp);

The Chinese area can be replaced by the following code.
if(extension_loaded(‘gettext‘)){         
date_default_timezone_set(‘UTC‘); 
return gmdate(‘Y-m-d H:i:s‘, $timestamp + 28800);}

#原理: Localized time formatting requires GetText support, if your environment does not turn on this feature, it will return garbled characters, affecting the processing of #phpmyadmin Ajax.
This test is validated on the phpMyAdmin 4.0.2 PHP 5.5.0 environment.

phpMyAdmin resolution when accessing the structure options of a table

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.