private function install_from_remote($url)
{
$fname = basename($url);
$dir_c = mw_cache_path() . 'downloads' . DS;
if (!is_dir($dir_c)) {
mkdir_recursive($dir_c);
}
$dl_file = $dir_c . $fname;
if (!is_file($dl_file)) {
$get = $this->app->url_manager->download($url, $post_params = false, $save_to_file = $dl_file);
}
if (is_file($dl_file)) {
$unzip = new \Microweber\Utils\Unzip();
$target_dir = MW_ROOTPATH;
$result = $unzip->extract($dl_file, $target_dir, $preserve_filepath = true);
return $result;
}
}