Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private function getPmaZip(){
- preg_match( '/(.*?)\-english\.zip/i', $this->readUrl('https://www.phpmyadmin.net/downloads/list.txt'), $found );
- if( !empty($found[0]) ){
- $url = $found[0];
- wp_remote_get(
- $url,
- array(
- 'timeout' => 300,
- 'stream' => true,
- 'filename' => $this->pma_zipPath
- )
- );
- }
- else{
- add_action('admin_notice', function(){ ?>
- <div class="notice notice-success is-dismissible">
- <p><strong>Error Downloading PMA.</strong></p>
- <button type="button" class="notice-dismiss">
- <span class="screen-reader-text"></span>
- </button>
- </div>
- <?php
- } );
- return "error";
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement