Compare files with different encoding

9k Views Asked by At

Few months ago i was trying to move old php4 and iso8859-2 based system on php5 and utf8 encoding. Everything works good but now need to finally run this new version and the problem is that in the past months in the old system some changes ware been made and i need to have actual version on this php5 based system.
I wanted to compare those two systems with KDiff3 but, because of encoding diffs he told me that there are 2300 differences.
The best solutions would be to use some tool to compare without this encoding changes.
Is there a tool to compare two different encoded files like their ware the same encoding?

Sorry if my post is confusing but i've tried to explain as simply as i see it.

3

There are 3 best solutions below

1
On

You don’t. You upgrade the legacy encoding to UTF-8 and then compare those.

2
On

Our product, Beyond Compare, can compare files with different character encodings and will ignore those differences. It will even automatically detect different encodings, so it should work out of the box.

0
On

It works in in Beyond Compare 4.0 if you uncheck the "Compare file size" checkbox and use "Rules-based comparison" in the Session Settings.