8
8
9
9
A comprehensive library for generating differences between two hashable objects (strings or arrays).
10
10
Generated differences can be rendered in all of the standard formats including:
11
+
11
12
* Unified
12
13
* Context
13
14
* Inline HTML
14
15
* Side by Side HTML
15
16
* Unified HTML
16
17
* Unified Commandline colored output
17
18
18
- The logic behind the core of the diff engine (ie, the sequence matcher) is primarily based on the Python difflib
19
+ The logic behind the core of the diff engine (ie, the sequence matcher) is primarily based on the Python difflib
19
20
package. The reason for doing so is primarily because of its high degree of accuracy.
20
21
21
22
## Install
@@ -58,23 +59,31 @@ echo $diff->Render($renderer);
58
59
```
59
60
60
61
### Example Output
62
+
61
63
A quick usage example can be found in the ` example/ ` directory and under example.php.
62
64
63
65
#### HTML Side By Side Example
66
+
64
67
![ HTML Side By Side Example] ( htmlSideBySide.png " HTML Side By Side Example ")
65
68
66
69
#### HTML Inline Example
70
+
67
71
![ HTML Inline Example] ( htmlInline.png " HTML Inline Example ")
72
+
68
73
#### HTML Unified Example
74
+
69
75
![ HTML Unified Example] ( htmlUnified.png " HTML Unified Example ")
70
76
71
77
#### Text Unified Example
78
+
72
79
![ Text Unified Example] ( textUnified.png " Text Unified Example ")
73
80
74
81
#### Text Context Example
82
+
75
83
![ Text Context Example] ( textContext.png " Text Context Example ")
76
84
77
85
#### Text Unified Console Example
86
+
78
87
![ Text Unified Console Example] ( textUnifiedCli.png " Text Unified Console Example ")
79
88
80
89
## Requirements
@@ -92,7 +101,7 @@ Have a look at [jQuery-Merge-for-php-diff](https://github.com/Xiphe/jQuery-Merge
92
101
93
102
* Ability to ignore blank line changes
94
103
* 3 way diff support
95
-
104
+
96
105
## Contributors
97
106
98
107
Contributors since I forked the repo.
0 commit comments