トップに戻る
tags
composer require jfcherng/php-diff
$old = 'This is the old string.'; $new = 'And this is the new one.'; $result = \Jfcherng\Diff\DiffHelper::calculate($old, $new, 'Unified'); // Context, JsonText, Unified var_dump( $result );
このように表示させることもできます
edit
添付ファイル