Forums

[resolved] Fix Arras-theme timthumb bug on Windows (1 post)

  1. Wolfflow
    Member
    Posted 3 months ago #

    Have searched quite for some hours but I got finally a great solution.
    You may find original post Here.

    Here a short summary:
    1.Edit file timthumb.php location: wp-content/themes/arras-theme/library
    2.Go to line 370 -(text say: Use PECL fileinfo ...)
    3.uncommnet following code lines:

    // if (function_exists('finfo_open')) {
    	//		$finfo = finfo_open(FILEINFO_MIME);
    	//		$mime_type = finfo_file($finfo, $file);
    	//		finfo_close($finfo);
    	//	}

    add following:

    $file_cmd = "file -ib \"$file\"";
          exec($file_cmd, $exec_output);
          $mime_type = $exec_output[0];

    4. Save the file.

    That worked for me. Hope it does for you too.

Reply

You must log in to post.

About this Topic