protected function extractToTemporary()
{
$this->filename = $this->file->getClientOriginalName();
$extension = $this->file->getClientOriginalExtension();
if ($extension == '') {
$this->filename = $this->filename . '.zip';
$extension = 'zip';
}
$temp_directory = str_replace('.' . $extension, '', $this->filename);
// Upload the theme zip file to temporary folder
$uploadSuccess = Input::file('file')->move(temp_path() . '/', $this->filename);
$file = temp_path() . '/' . $this->filename;
// get the absolute path to $file
// $path = pathinfo(realpath($file), PATHINFO_DIRNAME) . '/';
$full_path = pathinfo(realpath($file), PATHINFO_DIRNAME) . '/' . $temp_directory . '/';
$unzipSuccess = $this->Unzip($file, $full_path);
return $full_path;
}