Core Function
View Source on Trac ↗ wp_text_diff()
wp_text_diff( mixed $left_string, mixed $right_string, mixed $args = null ) Displays a human readable HTML representation of the difference between two strings.
Parameters 3 required
| Name / Type | Description |
|---|---|
| $left_string string | "old" (left) version of string. Required |
| $right_string string | "new" (right) version of string. Required |
| mixed | (string | array) $args { Associative array of options to pass to WP_Text_Diff_Renderer_Table(). Required |
Return Value
(string)
Empty string if strings are equivalent or HTML with differences.
Function Information
Since Version
2.6.0
Source File
wp-includes/pluggable.php
Advertisement