If you get some errors like ’
instead of apostrophe try the following
$contents = mb_convert_encoding( file_get_contents( 'FILEPATH_OF_PROBLEMATIC_FILE' ), "HTML-ENTITIES", "UTF-8" ); file_put_contents('FILEPATH_OF_PROBLEMATIC_FILE--FIXED', $contents);